8

A project won't compile because of a missing assembly. The file that causes the error has a

using Microsoft.VisualStudio.DebuggerVisualizers;

The VisualStudio part is marked in red. What do I have to install to fix it? To me it sounds like something that would have come with Visual Studio, but that is what I am using, so it is installed...

Clarification: I know what assembly it exists in, and the reference is added earlier to the project references. But how do I get it? What SDK do I have to install? Or have I forgotten to check something off when I installed Visual Studio?

Svish
  • 152,914
  • 173
  • 462
  • 620
  • @adrianbanks appears to have the correct answer here. The physical assembly lives in `%Program Files%\Microsoft Visual Studio 9.0\ Common7\IDE\PublicAssemblies` folder (assuming VS2008). (For VS2005, change the 9.0 to 8.) – Scott Dorman Aug 16 '09 at 18:33

4 Answers4

13

You should be able to find it in the "Add Reference" dialog in the .Net tab.

If not, the Microsoft.VisualStudio.DebuggerVisualizers.dll lives in the Common7\IDE\PublicAssemblies subdirectory of Visual Studio's installation directory. You could add it manually from there.

adrianbanks
  • 81,306
  • 22
  • 176
  • 206
  • Apparently, it ships with Visual Studio. It might be that you turned off a feature when you installed Visual Studio which has caused it to not be present. – adrianbanks Aug 16 '09 at 18:51
  • 7
    In VS2012 I found it in: C:\Program Files (x86)\Microsoft Visual Studio 11.0\Common7\IDE\ReferenceAssemblies\v2.0 – CrispinH Apr 12 '13 at 18:34
7

For Visual Studio 2010 the Microsoft.VisualStudio.DebuggerVisualizers assembly exists under C:\Program Files (x86)\Microsoft Visual Studio 10.0\Common7\IDE\ReferenceAssemblies\v2.0 (or relevant Program Files root).

For a debugger visualizer to target Visual Studio 2010 it must reference the 10.0 version of this assembly or it will fail with an invalid cast exception.

John B
  • 1,129
  • 14
  • 23
2

You should be able to find the assembly under the ".NET" list of assemblies in the "Add Reference" dialog.

Nader Shirazie
  • 10,736
  • 2
  • 37
  • 43
  • The current Debugger Visualizers walkthrough (as of late 2018) is for Visual Studio 2017 for a project targeting .NET Standard, and the Add Reference dialog no-longer has a tab named ".NET" - in fact all the tabs are now empty except for manual filesystem browse. – Dai Dec 30 '18 at 19:49
1

To anyone still looking for this - it's been moved to NuGet