Thursday, September 11, 2014

An unhandled exception of type 'System.Net.Sockets.SocketException' occurred in System.dll While trying to connect to MYSQL database from VB.Net 2003

Running VB.Net of Visual Studio 2003 on my 32 bit Windows 7 (with 2,7GB available memory) trying to make some Database Application.
Found out that the only compatible version of MYSQL Connector(Net) for Visual Studio 2003 is version 1.0. Newer versions will only get rejected while being added on "Add Reference".
While trying to connect to MYSQL database, an error occured saying:

"An unhandled exception of type 'System.Net.Sockets.SocketException' occurred in System.dll"

With additional information:
“An operation on a socket could not be performed because the system lacked sufficient buffer space or because a queue was full.”

Solution:

Visual Studio 2003 need .NET Framework 1.1 to run properly. But however, this was the cause of the problem above. Fortunately Microsoft provided the hotfix by releasing NET Framework 1.1 Service Pack 1.

Visit http://support.microsoft.com/default.aspx?scid=kb;en-us;826757 for detailed article.

or just google "net framework 1.1 service pack" to download the Service Pack

After installing Service Pack for .NET Framework 1.1, finally can get MYSQL accessible from VB.NET App