CoreStrings.DbContextMissingConstructor(Object) Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
'AddDbContext' was called with configuration, but the context type '{contextType}' only declares a parameterless constructor. This means that the configuration passed to 'AddDbContext' will never be used. If configuration is passed to 'AddDbContext', then '{contextType}' should declare a constructor that accepts a DbContextOptions<{contextType}> and must pass it to the base constructor for DbContext.
public static string DbContextMissingConstructor (object contextType);
public static string DbContextMissingConstructor (object? contextType);
static member DbContextMissingConstructor : obj -> string
Public Shared Function DbContextMissingConstructor (contextType As Object) As String
Parameters
- contextType
- Object
Returns
Applies to
Entity Framework