#90 – Stepping Into .NET Source Code in Visual Studio 2010

It’s sometimes helpful to see not only the metadata for .NET and WPF classes, but to actually step through the source code in the debugger to see how things are working.

To enable stepping through .NET source code in the debugger:

First, close any open solutions.  Then, under Tools | Options, select Debugging | General and check the option Enable .NET Framework source stepping.

Also check the Enable Source Server Support checkbox. Next, select Debugging | Symbols in the list at left.  Unselect Microsoft Symbol Servers, if it’s checked.  Click on the add button and enter http://referencesource.microsoft.com/symbols.  Then click on the Empty Symbol Cache button.

When you start debugging, you’ll see a message indicating that symbols are being downloaded.  This may take some time.

When you first try stepping into a .NET Framework method, you’ll see a EULA.

But then you’ll find yourself looking at .NET source code.  Voila!

Advertisements

About Sean
Software developer in the Twin Cities area, passionate about software development and sailing.

5 Responses to #90 – Stepping Into .NET Source Code in Visual Studio 2010

  1. Pingback: #115 – Downloading All .NET 4 Source Code « 2,000 Things You Should Know About WPF

  2. Alok Tripathi says:

    Hi Sean, now i want to reset my toolbox, as it was earlier, could you help me..
    Thanks in advance.

    • Sean says:

      Hi. Are you talking about resetting which items appear in the toolbox? You can do that by right-clicking anywhere in the toolbox and selecting “Reset Toolbox”. If you hid the Toolbox and want to show it again, go to the View menu and select Toolbox. If you want to reset where the Toolbox window appears, you can go to the Window menu and select Reset Window Layout.

      • Alok Tripathi says:

        Dear Sean,
        i have done these steps:::
        I followed these steps to enable stepping through .NET source code in the debugger(kindly see the link ,step by step what i had done before this problem emerged)

        https://wpf.2000things.com/2010/10/10/90-stepping-into-net-source-code-in-visual-studio-2010/#comment-445

        Now i want to reset my tool box. I did these steps but none work.

        1. devenv /resetskippkgs on VS command prompt

        2. right click on toolbox and rest toolbar

        3. right click on toolbox, then add new item then click Reset button.

        4. deleted 4 files from this location(toolbox.tbd, toolbox_reset.tbd, toolboxIndex.tbd, ToolboxIndex_Reset.tbd).

        %USERPROFILE%\Local Settings\Application Data\Microsoft\VisualStudio\9.0

        Let me know what else i do. All above action only showing the 3rd party tools that are attached to toolbox. tools are highlighted(can be drag and drop on page)

  3. Sean says:

    It sounds like maybe you deleted some files that you shouldn’t have deleted. I would uninstall and reinstall Visual Studio.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

%d bloggers like this: