LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

I need to program labview so that when I hit the run button graphical options will come up so that choose which one to run

I need to program labview so that when I hit the run button graphical options will display so that I can choose which option to run

0 Kudos
Message 1 of 7
(3,415 Views)

Hi gates,

 

after taking the beginner tutorials (which are for free) you could use a radio button connected to a case structure…

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 2 of 7
(3,406 Views)

@gates123 wrote:

I need to program labview so that when I hit the run button graphical options will display so that I can choose which option to run


if you mean hitting the run time arrow  of the "main vi" then....

Example_VI_BD.png

otherwise if it's a create state "run", then use a case statement in your "main vi". note: there are many different ways to do this Smiley Wink

option2_BD.png

Download All
0 Kudos
Message 3 of 7
(3,396 Views)

The run buttton in the tool bar is for development, not for a final program. I guess you are just asking how to make the program provide a selection when it starts, right? Leave the run button out of the discussion. 😉

 

You need to be significantly more clear with your question. Most of your words are very ambiguous and mean different things to different people:

What is a "graphical option"? How does it look like? Is this a popup?

What do you mean by "option to run" (e.g. open a different program, switch the current program to a different mode)?

0 Kudos
Message 4 of 7
(3,352 Views)

I am developing a program to run a stepper motor. The stepper motor is a part of a spectrometer that turn mirrors that should output wavelengths at different positions of the mirror. I want to develop a program in labview so that when I press the run button the vi it should give me two options. Option 1 is to take the mirror to home and option 2 is to start running normally. so it should pop up GO TO HOME or RUN NORMALLY. I should be able to choose either one.

 

Thanks

0 Kudos
Message 5 of 7
(3,344 Views)

@apok wrote:

if you mean hitting the run time arrow  of the "main vi" then....

Example_VI_BD.png


That first WHILE loop is meaningless, because the loop always exits after exactly one iteration. Just wire the boolean output of the dialog to the second loop boundary and delete the first loop for the same functionality.

0 Kudos
Message 6 of 7
(3,332 Views)

@gates123 wrote:

I am developing a program to run a stepper motor. The stepper motor is a part of a spectrometer that turn mirrors that should output wavelengths at different positions of the mirror. I want to develop a program in labview so that when I press the run button the vi it should give me two options. Option 1 is to take the mirror to home and option 2 is to start running normally. so it should pop up GO TO HOME or RUN NORMALLY. I should be able to choose either one.


Codewise, that's just a state machine with three states. (1) Ask for mode, (2) Mode#1, (3) Mode#2.

 

Still seems incomplete. Does the program need to be stopped to switch to a different mode or can it be used continuously?
What if the user wants to RUN NORMALLY after GO TO HOME has completed?

0 Kudos
Message 7 of 7
(3,330 Views)