unable to set breakpoint

Explore, browse and analyze .NET assemblies

Moderators: Luke Jefferson, Charles Brown, StephenC, Alex.Davies, Greg.Tillman, melvyn.harbour

unable to set breakpoint

Postby jlorenzon » Tue Mar 16, 2010 8:53 am

Hi I'm not sure if this is a problem with reflector or VS 2010 - I'm trying to debug into a .net assembly (System.Web.DynamicData). Following the instructions here, I can decompile it no probs, and view the decompiled assemblies also, no probs.

However, when I set a breakpoint I get an error message "Unable to set breakpoint" with a bunch of error details, and finishes by saying "the common language runtime was unable to set the breakpoint"

The breakpoint then shows up as disabled. Continuing to debug, the program will break at the breakpoint, but no information for any local variables will be available as the code is "optimized".
jlorenzon
 
Posts: 1
Joined: Tue Mar 16, 2010 8:31 am

Postby Clive Tong » Tue Mar 16, 2010 9:55 am

Hi.

We've not seen that message before when setting a breakpoint.

Do you have a small self contained example that you could send me that reproduces the problem? If not, what method are you trying to breakpoint?

Thanks
Clive Tong
 
Posts: 283
Joined: Thu Dec 04, 2008 5:42 pm

Postby MikeYeager » Fri Nov 12, 2010 10:09 pm

I'm experiencing this also, in my case I'm debugging a Windows Service, so I have to run the service, than attach the debugger to it. Visual Studio 2010. Maybe that's the problem? It's really annoying because I have to step through a LOT of code to get to the place I want to debug. OTOH, it's better than nothing! :D
MikeYeager
 
Posts: 4
Joined: Wed Feb 04, 2009 11:40 pm

Postby Clive Tong » Tue Nov 16, 2010 9:27 am

Can you give us any more details about the service so I can try to reproduce?

Thanks
Clive Tong
 
Posts: 283
Joined: Thu Dec 04, 2008 5:42 pm

Postby MikeYeager » Tue Nov 16, 2010 4:23 pm

I don't think I'll be able to spend the time required to create a simplified example, but I'll tell you what I can. We're hosting our Wcf Service in a Windows Service and using the Net.Tcp protocol with sessions enabled. Another thing we found was a dialog when trying to set a breakpoint saying that the dll we were debugging had been optimized. In the debugging session, I'm installing the Windows Service on my development box and running it under the Local System account (lots of rights). Then I start VS2010 and attach to the process with the debugger and set a breakpoint in my code. Once I step into the DLLs where the error occurs (Microsoft.Synchronization.Data and Microsoft.Synchronization.Data.SqlServer) I find that Step Over sometimes skips over several lines of code at once, so I always use Step Into instead. In a couple of instances, it seems to return from the middle of a method, several levels higher in the call stack for no apparent reason. Hope this helps...
MikeYeager
 
Posts: 4
Joined: Wed Feb 04, 2009 11:40 pm

Postby Clive Tong » Tue Nov 16, 2010 4:26 pm

Thank you for the information. I'll have a go at reproducing the problem.
Clive Tong
 
Posts: 283
Joined: Thu Dec 04, 2008 5:42 pm


Return to .Net Reflector 6.x and .NET Reflector 6.x Pro

Who is online

Users browsing this forum: No registered users and 1 guest