LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

VI running without white arror

Solved!
Go to solution

I have made a VI which monitor temperature. I have made a stand alone program from that VI but there is something that I am not pleased.

 

Is there way to replace the white arrow because I would want to hide it from user. The best way would be if there would be a way to make a running button on the front panel which do the same as the white arrow. Now I have configured that white arrow can't be seen by user and program runs when launched but if I stop the program I can't start it again without arrow.

 

I would be pleased if somebody could help me. Thank you.  

0 Kudos
Message 1 of 5
(2,747 Views)
You have to structure your code to be able to do that. What does your code look like? If you were to use a construct like a state machine you could easily do this.
0 Kudos
Message 2 of 5
(2,732 Views)

Basically I have a while loop which runs as long as user push a stop button (I attacghed a pic of my program). I would want to have a start button which behave the same way as the white arrow. So there isn't any "direct" ways to do so? Yes I understand what you ment by state machine but will I still have the same problem (I attaced a pic of state machine from labview examples (stop case))? When user push stop button the while loop stops and still there will be a situation when user need to push that white arrow to start the program again.

 

One other thing about state machine, isn't it bad for a application which should run N times? I want "living" program which shows its state whole time. I am not sure do you understand what I mean by that. I hope you do :).

 

Maybe there isn't a way to "replace" white arrow by button. 😞

Download All
0 Kudos
Message 3 of 5
(2,725 Views)
Solution
Accepted by topic author Pesonen
If you want the program to show its current state at all times, put an indicator on the state machine enum wire inside the while loop before it enters the case structure.

Create another state called Idle. Don't end the while loop when the state =Stop. When the stop button is pressed, direct it to go to the Idle state. In the Idle state, you can detect when the start button is pressed and then send it back to your initial Start state.  This Idle state will also be the first state that you go into after the Initialize state runs at the beginning of your program.

Create an Exit button that is separate from the Stop button. The Exit button will send it to a new state called exit. That is the state that will send a True to the overall while loop's stop terminal. With an Exit button, it is often a good idea to have it pop up with an "Are you sure?" dialog box. Only if the user hits OK on that dialog box will the True be sent to the stop terminal.
Message Edited by Ravens Fan on 06-28-2009 12:25 PM
0 Kudos
Message 4 of 5
(2,721 Views)
Thats a very good solution. Thanks Ravens Fan and all who helped. 🙂
0 Kudos
Message 5 of 5
(2,708 Views)