How do I “run until this variable changes” when debugging?

前端 未结 8 827
醉话见心
醉话见心 2020-12-30 23:29

When debugging my C#, I often want to know when a variable\'s value changes and then investigate the state of the program.

Currently, I do

8条回答
  •  灰色年华
    2020-12-31 00:00

    Here's how I do it in Visual Studio. Set a breakpoint by pressing F9 or clicking in the very left margin. Then right click over the red dot that appears and select the Condition command. There are other options there as well.

    However, this may not be supported in Visual Studio Express.

提交回复
热议问题