vajjalu

I am unable to hit breakpoints in both VS71 & VS80 (C++ Native). I originally had only VS71 installed on my PC and one day suddenly I was unable to hit any BPs. I dont remember what I did specifically to might have caused this behavior. I think I installed the .NET framework 3.0 around that time (uninstalling it hasn't had any effect). I then installed VS80 and the problem continued.

I have made sure of the following basic things that most people keep telling:
-- Building and running in debug mode
-- I am generating DEBUG info
-- Symbols are being loaded (seen in the modules and output window) and the dll and symbols both have the same time stamp (in both VS71 & VS80)
-- No optimizations in debug mode
-- BP is placed at a point where it is definitely being executed.

In VS71 - the BP glyph is a question mark and the message I get is "No executable code loaded at this location". In VS80 - the BP is a hollow circle with an exclamation mark and message I get is "The breakpoint will not currently hit. Unable to set breakpoint." Debugger breaks when exceptions are thrown, breaks when I use _DebugBreak() function.

I tried repairing VS71 but was of no help. I have tried almost every relevant solution that I could find on the web and have not been able to resolve the problem. Could someone please provide me with a solution to this problem.

Thank you.


Re: Visual C++ General Breakpoint Problem in VS71 & VS80

Holger Grund

I'm assuming this happens for new projects, too, right Sounds very odd, so I'm afraid I can't think of anything specifically. But to track down the problem:

What type of debugger do you use (you can choose it in the solution properties, or in the Debug->Attach dialog) Native/Win32 is what you want.

What happens when you __debugbreak() in your code Do you see the source code or the faulting instruction (i.e. the disassembly window) If you see the disassembly, does it mention the file of the source code file somewhere above the function prolog and what happens when you say Show Source Code from the context menu

Can you set a breakpoint by a function's name (You can name the function in the "New Breakpoint" dialog) If that works, does it show a breakpoint on the expected line

-hg





Re: Visual C++ General Breakpoint Problem in VS71 & VS80

vajjalu

I'm assuming this happens for new projects, too, right

-- Yes


What type of debugger do you use (you can choose it in the solution properties, or in the Debug->Attach dialog) Native/Win32 is what you want.

-- With Debug as the active configuration, I start debugging (F5)

What happens when you __debugbreak() in your code Do you see the source code or the faulting instruction (i.e. the disassembly window) If you see the disassembly, does it mention the file of the source code file somewhere above the function prolog and what happens when you say Show Source Code from the context menu

-- I see the source code, and I can only "step over (F10)" once.

Can you set a breakpoint by a function's name (You can name the function in the "New Breakpoint" dialog) If that works, does it show a breakpoint on the expected line

-- Yes I can set the BP by function and it shows up on the expected line.





Re: Visual C++ General Breakpoint Problem in VS71 & VS80

Holger Grund

I'm afraid I have no idea what could be the reason for that, sorry.

-hg





Re: Visual C++ General Breakpoint Problem in VS71 & VS80

Ramkrishna Pawar

Have you tried creating a fresh Win32 project (non .NET) and debug it If thats not working, then you need to reinstall (uninstall first) it from original disk.




Re: Visual C++ General Breakpoint Problem in VS71 & VS80

vajjalu

BPs dont work in new projects too. I tried a new MFC project.

I uninstalled VS71 and reinstalled it - the problem is NOT solved.




Re: Visual C++ General Breakpoint Problem in VS71 & VS80

Ramkrishna Pawar

Hmmm, this sounds stupid, but I need to ask, how are you setting breakpoints Also have you ever tried debugging and 'break all' Does it take to right source code Do other features of Visual Studio work

Try downloading the VC++2005 express edition and see if you can set breakpoints(create new win32 project) in it.






Re: Visual C++ General Breakpoint Problem in VS71 & VS80

einaros

vajjalu wrote:

What happens when you __debugbreak() in your code Do you see the source code or the faulting instruction (i.e. the disassembly window) If you see the disassembly, does it mention the file of the source code file somewhere above the function prolog and what happens when you say Show Source Code from the context menu

-- I see the source code, and I can only "step over (F10)" once.

You are unable to step multiple times through the disassembly window, or does this work as expected






Re: Visual C++ General Breakpoint Problem in VS71 & VS80

vajjalu

Ramkrishna Pawar
- I use the IDE to set breakpoints.
- I believe other features of VS work. I dont use a whole lot of them but I can use the watch (when I break using DebugBreak()), I get the modules.
- I already have VS80 installed and BPs dont work in that too.

einaros
- I can step through the disassembly but once I get to the next line of code, I cannot continue to step over.