03-15-2012 03:10 AM
I would like to create pause button to pause the process.
Then a Run button that when pressed will continue from where it last stopped at. .
Attached is my programme. .
I would really like your help. .
Thank you. .
oh and the while loop outside the stacked sequence structure is so that my programme will run when the start button on the front panel is pressed. .
Solved! Go to Solution.
03-15-2012 05:49 AM - edited 03-15-2012 05:51 AM
One simple approach would be to put the code in your While loop into the False case of a Case structure. Wire a "Pause" boolean control to the case selector and set its On text to "Resume". Put a small delay in the True case to prevent it from hogging the CPU during a pause and Bob will be your uncle.
Edit - make sure to set the mechanical action of the Pause boolean to Switch When Pressed/Released.
03-15-2012 08:10 PM
hi!
May I know what you mean by "set its On text to "Resume""?
Sorry I'm new to LabVIEW. .
03-15-2012 08:33 PM
Change the text that shows up on the boolean button. Go to the properties dialog for that button.
03-16-2012 01:44 AM
thanks!
03-16-2012 01:45 AM
hi. It still does not seem to be working for me. Sorry but could you help me see if I'm missing anything. .
Thanks. .
03-16-2012 05:03 AM
@jcarmody wrote:
One simple approach would be to put the code in your While loop into the False case of a Case structure [...]
You put the entire While loop into the Case structure; the Case structure belongs inside your loop.
03-18-2012 08:32 PM
oh yes!! it's working!! thank you so much! 😄
03-19-2012 02:28 AM
hi. one more thing. I want to make a button which clears the waveform chart when pressed. . help please. .
🙂
03-19-2012 02:46 AM
@Puchu wrote:
hi. one more thing. I want to make a button which clears the waveform chart when pressed. . help please. .
🙂
Add a case structure containing a property node for the chart history (right-click...create...property node...chart history) and wire an empty array to it (right-click...create...constant). Wire a latch action button to the boolean selector of the case structure. Place the case structure in parallel to the existing case structure so you can clear the chart independently of the main case state.
A few more points.