locked
The type initializer for 'System.Data.SqlClient.SqlConnection' threw an exception. RRS feed

  • Question

  • Last week Friday my application ran correctly, then after the weekend on Monday when I tried to run in again I got a ‘’Type Initialization Exception’’. I didn’t change any code so I do not understand why it threw that exception.  I also noticed that there was a warning on 1 of the referenced DLL’s  Microsoft.SqlServer.SString. and that the path was empty.

    In forums where other developers had the same Exception, they noted that the issue could be in the App.config file or it could a Windows Update. That would resolve my first issue but I also need to know why that referenced DLL lost its path.

    Tuesday, March 27, 2018 8:49 AM

All replies

  • What is Microsoft.SqlServer.SString, or is that a typo?

    This exception could result from many issues, so it helps to have as much accurate information as possible in order to troubleshoot the problem.


    Paul ~~~~ Microsoft MVP (Visual Basic)

    Tuesday, March 27, 2018 5:39 PM