Andrei Krotkov
Andrei Krotkov

Reputation: 5684

Data Breakpoints by Variable Name

Is there a simple way to define a breakpoint, in Visual C++ 2005, that will pause the program whenever a certain value changes? I found Data Breakpoints, but those require a memory address, and provide no simple way to tie that to a variable.

Upvotes: 1

Views: 677

Answers (1)

Ed Guiness
Ed Guiness

Reputation: 35247

"In the Address box, type a memory address or expression that evaluates to a memory address. For example, &avar to break when the contents of variable avar change."

http://msdn.microsoft.com/en-us/library/350dyxd0.aspx

Upvotes: 2

Related Questions