3

I've gotten ahold of the Microsoft Asp.Net source from http://aspnetwebstack.codeplex.com/

Is there a way for me to step into this source while also debugging my current ASP.Net application? I'd like to do this without adding the entire solution to my project.

For example: after setting a breakpoint and attaching to the asp.net process. I'd like to step into the asp.net source.

Kyle
  • 1,172
  • 1
  • 8
  • 23
  • If you're wanting to get into an HttpHandler or some other compiled code that is part of an application you may be able to step through that. However, if you want to step through the guts of IIS itself, that may be another story. Either way, I'd want an updated question at this point. – JB King Jul 08 '13 at 17:51
  • How does this not get back to my initial answer of just attaching the debugger as the way to see where you are in the code? I'm missing something here. – JB King Jul 08 '13 at 17:58
  • 2
    He wants to set a breakpoint in the ASP.Net framework code without adding the source for the framework to his solution. –  Jul 08 '13 at 18:00
  • So, load the source code into a running version of Visual Studio, attach the debugger and step through the code. As long as the other Visual Studio isn't currently debugging the IIS process that both sites are sharing, this should be doable. – JB King Jul 08 '13 at 18:01
  • I'm looking for some visual studio tip/trick to do debug both at once then – Kyle Jul 08 '13 at 18:02
  • No, the aspnetwebstack is a separate project from the .Net framework that would be more infrastructure I think. – JB King Jul 08 '13 at 18:46

2 Answers2

2

You need to enable .NET Framework source stepping and symbol downloads. Symbols and directions should be available from SymbolSource

Matt Self
  • 19,520
  • 2
  • 32
  • 36
1

To enable stepping through and set break points you need to enable the following in Debug-settings

In Tools -> Options -> Debugging -> General

Check Enable .Net Framework source stepping

Under Tools -> Options -> Debugging -> Symbols add the following:

See this link for a more detailed explanation.

As stated in a previous answer:

What you really need to do is exit your Visual Studio, run command

gacutil /u System.Web.Mvc

Then go to C:\Windows\Microsoft.NET\assembly\GAC_MSIL, remove or rename the offending System.Web.Mvc folder. After this, lanuch your Visual Studio and the "correct" System.Web.Mvc will be downloaded and you can step through the code and set break points.

Community
  • 1
  • 1
Mads
  • 444
  • 1
  • 5
  • 15