Innovative C# debugging experience with OzCode v4

Last week, in a Visual Studio Toolbox episode on Channel 9, Omer Raviv highlighted most useful features of the OzCode C# debugging extension for Visual Studio and announced upcoming version 4 introducing a live debugger accessible from a web browser.

With OzCode you can quickly search member names and values in collections and complex objects during debugging:

LINQ debugging and analysis visualizes how the different items passed through the LINQ pipeline. Indicators show you at-a-glance how many items were consumed by each LINQ operator, and how many were produced. The LINQ DataTip window shows the items the given operator produced:

The detailed analysis tool window lets you navigate between the LINQ pipeline using the operator breadcrumbs and take advantage of the animation to visualize the flow of the LINQ query:

A new feature coming to v4 of the extension is live coding. It compiles and run code in background as you type and shows calculated variable values in line with code:

It predicts code execution, unlike classical historical debugging, and lets you change it on the fly. Any code changes in the editor are immediately reapplied after typing and update calculated values, all within a single debugging session. When code with side effects is detected – execution stops.

[As a side note, live coding in Visual Studio was first implemented in 2015 by Josh Varty and Amadeus Wieczorek as the Alive extension. You can see it in action in a Codemash 2016 episode on Channel 9:

It worked in normal coding mode, not during debugging, and allowed to enter values for function parameters or extract them from unit tests. Later in 2016 the developers joined Microsoft and the extension was unfortunately discontinued. Then VS 2017 introduced Live Unit Testing which provides real-time feedback directly in the editor on how code changes are impacting your unit tests and your code coverage.]

Another upcoming OzCode v4 feature is collaborative debugging. It will allow you to share your current debug session with other people, not even necessarily having Visual Studio installed, using OzCode cloud debugger. Your colleagues will be able to interact with code from a web browser – view an actual execution that was captured and change the code to experiment:

OzCode version control system integration allows proposing and approving final code changes also from the same browser window:

See the full episode for more details. A personal OzCode license for 1 year currently costs $100.

Posted in Reviews | Tagged , , , | Leave a comment

Visual Time Spent v1.3 adds export to CSV and time spent percentage

Visual Time Spent automatically tracks your time spent working on solutions, projects and documents in Visual Studio IDE. It allows you to generate reports to see overall time spent and what activities took most time.

v1.3 adds the VS 2017 integration module to the main installer, export to CSV, time spent percentage and solution path tooltip.

Download the installer.

Posted in Vlasov Studio tools | Tagged | Leave a comment

ESharper v1.6.1 adds support for Microsoft.Office.Interop.Excel

ESharper is an Excel add-in that lets you write user defined functions and commands using C# interactively in a live Excel session.

v1.6.1 adds default reference to Microsoft.Office.Interop.Excel.dll providing access to the Microsoft.Office.Interop.Excel library.

Download the installer.

Posted in Vlasov Studio tools | Tagged | Leave a comment

Runtime Flow v1.8.0 adds simpler VS 2017 integration and global keyboard shortcuts to pause and resume monitoring

Runtime Flow in real time monitors and logs function calls and function parameters in a running .NET application and shows a stack trace tree, with no instrumentation or source code required for monitoring.

v1.8.0 adds the VS 2017 integration module to the main installer and includes the RFShortcuts extension to resume and pause monitoring with global Windows keyboard shortcuts Win+F11 and Win+F12.

Download links: Visual Studio edition, Portable edition.

Posted in Vlasov Studio tools | Tagged , | Leave a comment

Tabs Studio v4.3.1 includes CloseRight and SuperCommands add-ins

Tabs Studio is a Visual Studio and SSMS extension empowering you to work comfortably with any number of open documents.

v4.3.1 adds CloseRight and SuperCommands add-ins to the installer, fixes the inability to install Tabs Studio for VS 2017 with running background Visual Studio processes.

See the full what’s new list. Download the installer.

Posted in Vlasov Studio tools | Leave a comment

Command and extension examples for Visual Commander

Visual Commander is a freemium extension for Visual Studio 2012+ allowing you to automate repetitive tasks in the IDE.

v2.7 adds command and extension examples accessible from the main VCmd menu:

Click Edit to view command code, experiment with it and execute:

Note that changes in example code are not saved once you close Visual Studio. Click Save in the Command Examples window to copy the selected example to normal commands where you can persist changes and assign a keyboard shortcut to the command.

Download the installer.

Posted in Vlasov Studio tools | Tagged , , , , | Leave a comment

Changing Visual Studio 2017 private registry settings

Visual Studio traditionally includes several settings that can be set only in registry (HKEY_CURRENT_USER\Software\Microsoft\VisualStudio\[version] key). For example, Find result format, UseSolutionNavigatorGraphProvider or EnableVSIPLogging.

Visual Studio 2015 registry settings

Visual Studio 2015 registry settings

Visual Studio 2017 continues to support these settings, but now uses the RegLoadAppKey function to store registry keys in a private binary file under %LOCALAPPDATA%\Microsoft\VisualStudio\15.0_ [id]\privateregistry.bin:

To edit this file in Registry Editor, first make sure Visual Studio is closed (plus it takes about 20 seconds for all Visual Studio background process to shutdown), then select HKEY_LOCAL_MACHINE or HKEY_USERS and then File – Load Hive…:

When the file is loaded, you can change registry settings as usual:

Don’t forget to unload the hive when finished, or you will get an unknown error loading Visual Studio:

You can automate hive loading and unloading with the following VS2017PrivateRegistry.cmd batch file (close target Visual Studio 2017 instances with the background processes and then run the file with administrator rights):

for /d %%f in (%LOCALAPPDATA%\Microsoft\VisualStudio\15.0_*) do reg load HKLM\_TMPVS_%%~nxf "%%f\privateregistry.bin"
regedit
for /d %%f in (%LOCALAPPDATA%\Microsoft\VisualStudio\15.0_*) do reg unload HKLM\_TMPVS_%%~nxf

It loads registry keys for all Visual Studio 2017 instances as HKLM\_TMPVS_[id], starts Registry Editor and unloads keys when you close Registry Editor:

If you do have multiple instances of VS 2017 installed (e.g. Community and Enterprise, or a general release and a preview) and want to find corresponding instance ids, you can use the Visual Studio Locator utility. Included with the installer as of Visual Studio 2017 version 15.2 and later at %ProgramFiles(x86)%\Microsoft Visual Studio\Installer\vswhere.exe:

If you want to quickly set a registry setting to a specific value, there is a simpler approach. A running Visual Studio 2017 instance not only loads registry keys with the RegLoadAppKey function from the privateregistry.bin file, but also redirects all registry operations under the HKEY_CURRENT_USER\Software\Microsoft\VisualStudio\15.0 key to the private registry. Code running in the Visual Studio 2017 process can use standard registry API to set these settings:

var key = Microsoft.Win32.Registry.CurrentUser.CreateSubKey(@"Software\Microsoft\VisualStudio\15.0");
key.SetValue("UseSolutionNavigatorGraphProvider", 0);

Just execute the following commands once from Visual Studio (e.g. with the Visual Commander extension) to set corresponding settings: Change find result format to remove the full path, Hide class info in Solution Explorer, Show the GUID and ID of menu or command when Ctrl+Shift is pressed.

As you see, customizing Visual Studio 2017 with internal settings is still possible with a bit more work.

Posted in Visual Studio tips | Tagged | Leave a comment