This Visual Studio 2012 Debug Visualizer will show the hex values of a given string and the text value in a split window, revealing what is otherwise hidden data. This is useful when working, for example, with data that is read from a file that may have come from a *nix system and contains different line endings (CR vs CR/LF).
To use this visualizer with other versions of Visual Studio, just change the Microsoft.VisualStudio.DebuggerVisualizers references to the version that aligns with your Visual Studio version.
- Either compile the source -or- download the executable.
- Copy the executable from the compiled source (<home>\StringVisualizer\bin\Debug\StringVisualizer.dll) or the download to <MyDocuments>\Visual Studio 2012\Visualizers
- Restart Visual Studio.
When debugging a project you can hover on a String variable and select 'Advanced String Visualizer' from the spyglass icon in the tool-tip, or from the spyglass icon in the Locals or Autos windows.