I am getting below error while run Add-Migration InitialCreate
migration command. I am using ASP.NET CORE 2.0.
An error occurred while calling method 'BuildWebHost' on class 'Program'. Continuing without the application service provider. Error: Table 'Temp.contacts' doesn't exist Unable to create an object of type 'ApplicationDbContext'. Add an implementation of 'IDesignTimeDbContextFactory' to the project, or see https://go.microsoft.com/fwlink/?linkid=851728 for additional patterns supported at design time.
To resolved this error, I have tried to add a class that implements IDesignTimeDbContextFactory
but doesn't work it.
Anyone knows why I got this error?