LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Having issues with using an event structure to detect value change

Below is what I am trying to do. I need to control a switch with two switches as I have done. I need to read the latest "boolean text" and the "text label" of the switch as it changes. It would seem like a simple problem but I will have more than one switch that may be on at the same time which is why I am using an event structure to find the last changed value.

As you can see the problem is my text doesnt change as the switch changes. Can you help??
Any advice much appreciated

Alexi
0 Kudos
Message 1 of 7
(3,600 Views)
Instead of using the Value property, you have to use the Value(Signaling) in order to fire the event.
0 Kudos
Message 2 of 7
(3,600 Views)
I changed your VI a little see if this is close to what you are trying to do. You also may want to purchase a Book called Labview for everyonr second edition if you are just beginning labview.

Joe



Joe.
"NOTHING IS EVER EASY"
0 Kudos
Message 3 of 7
(3,600 Views)
Hi, I will explain the problem as a whole and see if you can help...

Below I have attached my vi - alert panel. This is used as a control to trigger different alerts in another vi in the order they occur, where I need to be able to turn each alert off individualy. My panel works great except for the turning switches off from another vi part. I use the data from the ques to trigger alerts, but how do I write back to the switches in the cluster in the event structure to disable the alerts? I tried using globals,which have no effect... Please help,

Alexi
0 Kudos
Message 4 of 7
(3,600 Views)
alexi,

You have the right idea with the locals, but you just didnt implement them correctly. I have modified your vi to show how to reset all of the switches in the simpliest way i know its not pretty but if gives you the idea of how to do it. You will have to write a bit more code to clear all the errors though.

(I had to delete the globals)

Regards

Anthony Sims
Applications Engineer NI-UK
0 Kudos
Message 5 of 7
(3,600 Views)
hi,

thanks for the help. I need my vi to be able to do as you have shown me, except when I press clear I need the switches to automatically turn off. As is now I need to change a value of a switch to get the clear to take place.I would just clear the queue but I need to be able to change the value of individual switches and leave others on. My problem is that this vi is running in the background of other vi's so I wont access it much but will need to write to these switches. Do you know a way to do this?
If the switches werent in an event structure I would just write to them with globals.


thanks for any help,

Alexi
0 Kudos
Message 6 of 7
(3,600 Views)
dont worry I have just figured it out.
Thanks for your help it inspired me to find a new way of addressing the issue.
thanks

Alexi
0 Kudos
Message 7 of 7
(3,600 Views)