Hey!
Last week Karen K. Liu (PM /C# MS) had a presentation at TechEd in Barcelona about tricks and tips using visual studio and more. One of this tip was to Customize autoexp.cs found in ${mydocuments}/Visual Studio 2005\Visualizers\
I have a Class named MyClass which can be found in the MyNamespace and is located in MyFile.dll, and what i write in the autoexp.cs file is :
using MyNameSpace;
[assembly: DebuggerDisplay(@"\{Count = {count}}", Target = typeof(MyClass))]
and when debugging i want to display the count parameter of MyClass when i hold the mouse over the object.
What else is needed to get this to work? I have restarted VS 2005 after editing. A weird thing is that I also changed the DebuggerDisplay for Font (which is already used in the autoexp file), and i created a instance of Font in my [TestMethod]. But not even
the font object displayed accordingly to what i wanted.
Somehow it looks like the autoexp.cs file is never read...
Anyone have a clue?
/Halvor
-
-
If you have access to the source code of the class, you could just add the DebuggerDisplay attribute to the class itself.
-
Thank you for trying to help me, but the file is shared among 30 developers, and i do not want to add my private debugging preferences to the Core module. I would like to have my private set of display attributes.
Thread Closed
This thread is kinda stale and has been closed but if you'd like to continue the conversation, please create a new thread in our Forums,
or Contact Us and let us know.