03-07-2009 11:17 PM
Hi all,
In debug mode, how do I change a value? For example, if a wire has a boolean false value in it, when I am stepping through the program, can I change it to true, so that the program can respond accordingly? Thanks!
Yik
03-08-2009 01:46 AM
Probes are passive, you cannot inject new data into the wire.
What you need to do is add a bit of code to troubleshoot. For example, you could disconnect the data source of a wire and replace it with a diagram constant or FP switch, or you could inser an "invert" to see what happens down the wire if the boolean were the opposite. You just need to be a bit creative.
Make sure to save the VI before you start messing with it this way. 😉
03-08-2009 12:33 PM
03-08-2009 12:55 PM - edited 03-08-2009 12:56 PM
As was already said, you can't do this on a wire-level. But you can do this on a VI-level when stepping through your code. You can set a property on a VI called Suspend When Called. When execution reaches the subVI, it will pause before continuing. You will have a chance to see the values on your input controls attached to the connector pane and update them before continuing execution. For instance, if you had a boolean input control that had a False value, you could toggle it to True and then unpause to continue.
This property is in the VI Properties dialog in the Execution section.