Today installed a full green version of vc++6.0 and then breakpoints can be set, but not debug, so the Internet search, according to several versions of the change, and finally succeeded, reproduced out to share
One or more breakpoints cannot to be set and have been disabled ...
Error behavior: The step info in debug or run to cursor a breakpoint will appear with one or morebreakpoints cannot be set and have been disabled. Execution would stopat the beginning of the program.
Solution,
1. In Project->setting->c/c++-general->debug info->program databse for Edit and continue;
2.edit->breakpoints->removeall;
3.build->set active project Configuration->*.exe Win32 Debug.
After three steps, ok!
Another article:
One or two kinds of debugging methods:
1, Debug mode:
2, Release mode:
Click the menu [Project]->[settings ...] to appear in the Project Settings dialog box and select Release status.
Select the category Selection general,optimizations disable (debug) and debug info to choose Program Database.
Select the Generate Debug Info check box in the Link tab.
Note: Release mode is slightly better, because some cases can only run in the program, such as "DLL showing dialog box" in Debug display window after the dead there.
Possible errors in debugging: "Cannot Debug", "Breakpoint error."
1, "Cannot Debug":
"One or more breakpoints cannot to be set and have been disabled." Execution'll stop at the beginning's program.
2, "Breakpoint Error":
"One or more breakpoints are not positioned on valid lines." These breakpoints have been moved to the next valid line.
Note: "Cannot debug" is not the same as "Breakpoint error", "Breakpoint Error" Disables certain error breakpoints, but "cannot debug" disables all breakpoints.
Third, the solution
1, for "Breakpoint error", VC will automatically help us locate a line, we do not have to ignore.
2, for "Cannot debug", the resolution steps are as follows:
1), restart the computer
2, the project copy to the new directory, delete NCB,. opt,.plg file. Note that the copy is not cut.
3), and then menu bar: Build->rebuild all.