Reputation: 14468
Just installed WebMatrix and upgraded Visual Studio 2012 to Version 4.5.50709 SP1Rel. Now when I open my webapplication I get a bunch of errors of this type:
'IIf' is not declared. It may be inaccessible due to its protection level.
'IsNothing' is not declared. It may be inaccessible due to its protection level.
'IsNumeric' is not declared. It may be inaccessible due to its protection level.
I get so many errors that I even get this:
Error 104 Maximum number of errors has been exceeded.
Upvotes: 1
Views: 1336
Reputation: 1
I just ran into the same problem in VS 2012 when attempting to copy over an old version of a program I received from another colleague.
As muleskinner says, it is not a reference issue to Microsoft.VisualBasic
...
When you try to add that as a reference it will tell you that it is already automatically referenced by the build system.
It turns out that even though Microsoft.VisualBasic
is automatically referenced, the project didn't actually have the namespace imported.
You can add it by going to the properties of your project -> References
-> And then make sure that Microsoft.VisualBasic
is checked in the list of namespaces at the bottom.
At least that worked for me and cleared up all my errors. Wasn't relishing trying to change all my IIf statements into the more traditional format...
Upvotes: 0
Reputation: 14468
It turned out that during WebMatrix installation or Visual Studio upgrade MySql Connector version 6.5.4.0 was also installed.
Somehow MySql Connector v. 5.1.5, which my project were referring was uninstalled in the process.
Reinstalling MySql connector 5.1.5 solved the issue. Changing the reference to the new MySql connector would probably also solve the issue.
Upvotes: 2