Ambiguity issue with Vb.Net and MySql Connector

181 views Asked by At

I'm running into a weird issue with a VB.Net project using the MySql ADO.Net connector. I have the following code:

Dim param As New MySqlParameter("@val29", MySqlDbType.DateTime)

And I'm getting the following error message:

Ambiguous invocation:
  Public Enum member Datetime As MySqlDbType (in Enum MySqlDbType)
  Public Enum member DateTime As MySqlDbType (in Enum MySqlDbType)
match

The difference between them, if you notice, is that DateTime is in a different case then Datetime. Since this is VB.Net and VB is case-insensitive, I'm not sure why I'm getting this error.

Interestingly enough, I opened Object Browser in Visual Studio 2013 and, as you can see from the image below, there does seem to be two definitions of DateTime:

Screen Shot .

Thinking maybe there was an issue with the DLL, I went to their website and downloaded the source code and rolled my own DLL. Same issue. I couldn't seem to find anything on the Internet about it, except for this page, which describes my issue exactly, except it seems to be due to a specific bug in Visual Studio 2015. I'm using Visual Studio 2013. That almost makes me think a Windows Update came along that changed the way the VB.Net compiler works. That doesn't make any sense though because updates are specific to Windows, not Visual Studio. Anyone have any ideas?

0

There are 0 answers