In my program, a recursive state is being used. The state judge some conditions,and call itself or exit.
In the state, I want check the UI event. I adds "Idle" state in the front of the state queue,but found it will empty the queue.
My question: How to check the UI event or Jump to "Idle" state programly?
JKI Discussion Forums
Page 1 of 1
How can I check the UI event in code?
#2
Posted 25 May 2011 - 05:01 PM
I am not sure what you mean by "it will empty the queue", but here is what you should do.
If you do all of the above, this should work fine.
Below is a screenshot and an example written in LabVIEW 2010.

Hope it helps.
Philippe
- Make sure that you have a timeout different from -1 for the event structure (ex: 100)
- Make sure that you append in the front of the queue
- Make sure that the remaining state is connect to the state in of the "add states to queue" vi in every frame (this could explain your empty queue).
If you do all of the above, this should work fine.
Below is a screenshot and an example written in LabVIEW 2010.
Hope it helps.
Philippe
Attached File(s)
-
SM question.vi (53.5K)
Number of downloads: 52
Share this topic:
Page 1 of 1



Back to top








