Asp update not updating
You see that I registered an Async Post Back Trigger on the Click event of the button.
I also added a label that will be updated by the event raised by the textbox.
Either while inserting new entries into the database (in which case you might encounter the error above), or while running Update-Database in a code-first ASP.
NET MVC5 EF6 -project, you get a following (or similar) error: This can be thrown by a plethora of different issues.
This post describes an issue with EF’s code-first migrations, when mapping between DB’s Date Time (datetime2) and C#’s Date Time simply fails, and results in the Update-Database cmdlet failing, too.
It’s more or less a prime example of a situation, where the error itself tells very little about the actual issue, and since debugging code-first migrations is kind of difficult (see the best tips for that here! I’ve encountered this error in 2 different situations.
We use to update these through Nu Get, but those days are now behind us.
By far the easiest option is to use their hosted versions.
If you have ever used Nu Get packages, you are going to feel right at home.
Let’s walk through this by updating Bootstrap with Visual Studio 2017.