From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.

We appreciate your patience as we improve our online experience.

LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Forcing position of a control using code

Solved!
Go to solution

I have a Piping Diagram on my front panel in which I place a custom control for switching a valve on and off. My program has a number of automated sequences as well as a "manual" mode. In manual mode I would like change the state of my valve by simply pressing the control (which looks like a valve on the diagram). This part I can do now. However I would also like for the valve control to change state via my code during the automated sequence--i.e. I would like to force the control via code instead of via front panel interaction so that my piping diagram displays my valve status during the automated sequence. Alternatively I could have the valve on the diagram be a indicator instead of a control, but I want the manual control to occur by pushing the valve on the diagram, not somewhere else. So I could do that by having an invisible control right on top of the indicator, but I don't know how to do that either.

Is it clear what Im asking?

Can anyone help?

Thanks,

Ron

0 Kudos
Message 1 of 4
(2,319 Views)

Yes you can put a button over another indicator

 

tank button.png

=====================
LabVIEW 2012


0 Kudos
Message 2 of 4
(2,313 Views)
Solution
Accepted by topic author rsi77

If you want a simple way, just create a local variable of the control and write to it.

Message 3 of 4
(2,306 Views)

Yes, local variable makes this quite easy. I didn't even know what they were before this.

Thanks,

Ron

0 Kudos
Message 4 of 4
(2,295 Views)