LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

accessing a case selector

how to access a case selector through a command button???

0 Kudos
Message 1 of 5
(2,437 Views)

What do you mean by accessing?. If you have wired you can click the button at the front panel to change the state and when you run your code the respective case will execute

 

For your other question here : Yes run it inside a while loop with the button inside. Go through the online LabVIEW tutorials you will get an idea

-----

The best solution is the one you find it by yourself
0 Kudos
Message 2 of 5
(2,434 Views)

We are able to do what you explaineed. But we dont want to click run again after changing the value. It should run the required case automatically once the value is changed. can we do so? is that possible? if not, how to do? please help. We are very new to labview.

0 Kudos
Message 3 of 5
(2,430 Views)

You have to use the event structure to capture the value change you can place your code inside the event structure as like you place it in the case structure but while doing that your code will not take much time to execute. This and this would be helpful for you

-----

The best solution is the one you find it by yourself
0 Kudos
Message 4 of 5
(2,425 Views)

@vidhya_1309 wrote:

We are able to do what you explaineed. But we dont want to click run again after changing the value. It should run the required case automatically once the value is changed. can we do so? is that possible? if not, how to do? please help. We are very new to labview.


You make very little sense here. how can it "run a case" in edit mode?

 

A minimal topelevel program needs a while loop around the core diagram code. It is either in edit mode while you are change the program by editing the diagram, or it is in running, where you interact with the front panel and the code does it's part. The while loop ensures that the program keeps running until you stop it.

 

Sure, later to can enhance the code with an event structure and such, but I would recommend to start with the basics. Start with some tutorials and look at the examples in the example finder.

 

Feel free to attach your VI so we get a better idea what you are doing and can possibly give you some more specific advice.

0 Kudos
Message 5 of 5
(2,418 Views)