Test controllers are not visible or marked offline in MTM when multiple versions of MTM are installed

When you have two or more versions of Visual Studio installed on a single machine and you try to use the newer version of mtm to connect to an older version of Test Controller, the Test Controller shows offline.

The event log shows the following error message:

Log Name: Application
Source: VSTTExecution
Date: 5/20/2014 2:58:45 AM
Event ID: 0
Task Category: None
Level: Error
Keywords: Classic
User: N/A
Computer: machineName
The description for Event ID 0 from source VSTTExecution cannot be found. Either the component that raises this event is not installed on your local computer or the installation is corrupted. You can install or repair the component on the local computer.
If the event originated on another computer, the display information had to be saved with the event.
The following information was included with the event:
(mtm.exe, PID 4420, Thread 8) ControllerConnectionManager : InternalConnect : System.InvalidCastException: Unable to cast transparent proxy to type ‘Microsoft.VisualStudio.TestTools.Controller.ControllerObject’.
at Microsoft.VisualStudio.TestTools.Controller.ControllerConnectionManager.InternalConnect(ControllerConnectionInfo controllerConnectionInfo)
the message resource is present but the message is not found in the string/message table

Let’s say you have Visual Studio 2012 and Visual Studio 2013 installed on one machine and you are trying to connect to Test Controller 2012. In that case, you can use the following workarounds:

1) Use assembly redirection in mtm.exe.config. Add the following under <assemblyBinding> node in mtm.exe.config v12.0 (C:Program Files (x86)Microsoft Visual Studio 12.0Common7IDEmtm.exe.config):

        <assemblyIdentity name=”Microsoft.VisualStudio.QualityTools.Common” publicKeyToken=”b03f5f7f11d50a3a” culture=”neutral”/>
        <bindingRedirect oldVersion=”″ newVersion=”″/>
        <assemblyIdentity name=”Microsoft.VisualStudio.QualityTools.ControllerObject” publicKeyToken=”b03f5f7f11d50a3a” culture=”neutral”/>
        <bindingRedirect oldVersion=”″ newVersion=”″/>
        <assemblyIdentity name=”Microsoft.VisualStudio.QualityTools.ExecutionCommon” publicKeyToken=”b03f5f7f11d50a3a” culture=”neutral”/>
        <bindingRedirect oldVersion=”″ newVersion=”″/>

 2) Use mtm 2012 to see online controllers

Basically, you need to use assembly redirection for the above three assemblies and let them point to the version of mtm client that you are using.