Daves answers.
And I will add that you can just add an if statement containing a couple of dummy statements, and you put a breakpoint in it. He does the same.
Typical Usage:
if (i == 250) { int dummy = 2+2;
In your case, since you are looking at the value of a string (assuming C ++ strings)
if (mystring == "hello") { int dummy = 2+2;
source share