Delphi 2009 only halts at breakpoints in one unit

debuggingdelphidelphi-2009

I'm experiencing problems with debugging in Delphi 2009's IDE. Since having moved old projects that had been created using Delphi 7 to this version, all breakpoints except for those in one unit are neglected. I couldn't figure out which unit that is, but that seems to change from time to time.

Enabling debug DCU's overcomes this phenomena, but I don't want to step inside RTL/VCL units. Only those used by my project, like the Version 7 IDE did with standard settings.

Best Answer

Chances are when you first moved the project to D2009 you built your units without debug info. Now that those units have been created, they don't get rebuilt every time. What you are probably seeing is that the breakpoint only works in the unit you're currently editing and making changes to. This is consistent with the fact that the compiler knows to rebuild that unit (with the now properly set debug flags), and that unit only.

The solution is the make sure the Debug configuration is selected and then do a full build.

Related Topic