06-21-2013 04:40 AM - edited 06-21-2013 04:47 AM
I am using the packet sniffer example in my code with some modifications to calculate delay of my transmitted data.
I need to make a dynamic call to run this VI at some point of my main code and stop at some other point.
Just to test I put some delays between run, stop and get delay as below:
But in the VI that I am calling, the stop button is inside an Event structure... like here:
So... even if I try to stop the VI in my dynamic call it seems that my VI will not read this change... only read if I manually stop in the VI.
so I try to stop in the first VI but doesn't stop.... what could be a solution for that??
thanks,
Thais
Solved! Go to Solution.
06-21-2013 07:11 AM
Solved problem. I just inserted the stop button in the same case where is Timeout, now I can guarantee that this value will be read.
06-21-2013 09:32 AM
That's because using Ctrl Value.Set is programmatically setting the value of the control, it doesn't trigger a value change event. If you were in the same VI, it is like using the Value property node when you would need to use Value(Signalling) in order to force the value change event to fire.
Another way to do this would be to register a user event and send it to the subVI, and generate a user event to fire an event case. Then you wouldn't need to use the timeout case to effectively poll your stop button.