SQL Dependency Tracker 2

System.TypeInitializationException on start

This page applies to SQL Dependency Tracker version 2.2 only. This issue is fixed in SQL Dependency Tracker versions 2.4 and later.

When you start SQL Dependency Tracker, you may encounter a System.TypeInitializationException error.

One possible reason for this is that duplicate third-party components are installed on the local computer.

There are separate versions of the DevExpress components for .NET 1.1 and 2.0. If versions for both .NET 1.1. and .NET 2.0 are installed, a problem can occur if DevExpress signed the two different versions with the same key. Another piece of software has installed the wrong version into the Global Assembly Cache. If the same components exist both there and in the local folder of SQL Compare and SQL Data Compare, .NET will always load from the General Assembly Cache.

Solution

SQL Dependency Tracker versions 2.4 and later have a fix for this issue. Use SQL Dependency Tracker's Help > Check for Updates to upgrade to the latest version of SQL Dependency Tracker. 

If it's not possible to upgrade, as a short-term fix:

  1. Copy the DevExpress assemblies from %systemroot%\assembly to the local folder of the application that needs these versions.
    This application is probably either ReSharper or NUnit.
  2. Delete the DevExpress assemblies from %systemroot%\assembly.

For more information, see this forum post.


Didn't find what you were looking for?