LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

how to make stop and start in one button

Hello All

 

My Question is how to make button that when I prees it first time work as stop button and when I press it second time work as start button, I hope if I found my answer soon.

thank u all

 

Best Regards

0 Kudos
Message 1 of 13
(18,740 Views)
Hello,

What's your labview version?
Software developer
www.mcm-electronics.com





PORTUGAL
0 Kudos
Message 2 of 13
(18,728 Views)
We would probably need a bit more info.
 
If you want a button that starts running the VI, that won't be easily possible, because the VI needs to be running in order to read the button state.
 
Typically, you would just set the mechanical action of your button to "switch action" and wire it to a case structure in a loop containing a small delay. Put the run code in one case and leave the other case empty. Now the switch will select which case executes for each iteration. Use different labels for the two button states (run|stop for example)
 
If your problem is more specific, please attach a simple version of your VI and explain how it should behave. 🙂
0 Kudos
Message 3 of 13
(18,723 Views)
I've made this quick example. But you can only see it if you've labview 8.5.
Software developer
www.mcm-electronics.com





PORTUGAL
Message 4 of 13
(18,722 Views)
It's probably not worth to add all these sequences, local variables, and parallel loops. Here's a somewhat simpler version, showing two possibilities: 0:using events, 1: not using events. Pick one! 🙂
 
There are many other possibilities. It really depends what else there is.

Message Edited by altenbach on 10-15-2007 06:59 AM

Message 5 of 13
(18,705 Views)
IOIOIOI


I'm a complicated person.

Smiley Very Happy
Software developer
www.mcm-electronics.com





PORTUGAL
0 Kudos
Message 6 of 13
(18,696 Views)
Thank u all 4 ur help specially my brothers   "Jorge Amaral"  and  "altenbach"
and sorry to say that it dosn't work with me coze the version that I have is 8.2
 
Best Regards
0 Kudos
Message 7 of 13
(18,677 Views)
That's why we always should mention our labview version when we post a question. In attach follows our friend version (it's simpler than mine)

Smiley Very Happy


Software developer
www.mcm-electronics.com





PORTUGAL
0 Kudos
Message 8 of 13
(18,669 Views)


@Mirage wrote:
Thank u all 4 ur help specially my brothers   "Jorge Amaral"  and  "altenbach"
and sorry to say that it dosn't work with me coze the version that I have is 8.2

My example was posted in LabVIEW 8.0, so you should have been able to open it easily. Check again.
0 Kudos
Message 9 of 13
(18,659 Views)

Thankx so so so so so so so so so much

"Jorge Amaral"  and  "altenbach"

ur examples work 100 %

thankx again 4 ur help

Best Regards

 

0 Kudos
Message 10 of 13
(18,647 Views)