i2dx Posted January 6, 2005 Report Share Posted January 6, 2005 Hi Folks, i have a problem using multiple event-structures with subpanels. to be more precise: i have a main VI with a subpanel in which several VIs are called for different tasks. These "Sub-VIs" are called via VI-Server (Reference --> set Controls --> Run VI [wait until finished: FALSE, auto dispose Refnum = FALSE]) and terminate themselfes. I have allready checked if they maybe do not terminate correctly before unloading from the subpanel, they are terminated. the problem is: the event structure in the main VI misses events: i have 2 booleans and a cluster of 6 booleans on the front panel of the main VI and the events on the single boolean controls are not recognized by the event structure (even if there is a allready terminated sub-vi without event-structure in the subpanel) after calling a "Sub-VI" with an event structure in it. on the other hand, the events on the booleans in the cluster are still recognized. an easy way to "fix" this problem would be to drag all boolean controls into the cluster. But i would prefer to know why this happens. If anyoune knows what's going on there, please let me know. If you need some code examples, i have uploaded some screenshots to my homepage. i cant show you the complete code, because the project is very large. if you need more information, please let me know the Main VI (Queued State Machine) running a "Sub-VI" Main-Frontpanel the Buttons "Einstellungen" and "Ende" arre the missed ones Quote Link to comment
didierj Posted January 6, 2005 Report Share Posted January 6, 2005 Do your two booleans are (in the written code) handled by the event structure? If so and the two booleans are "latch" booleans, then they have to reside IN the corresponding event cases. Although an event structure handles the event of controls, it does NOT read the control. This means for booleans with latch they never get read if you don't have them (the control terminal not a ref/local variable/property node) in the structure. Your event is handled only once. Hope this helps... Didier Quote Link to comment
i2dx Posted January 6, 2005 Author Report Share Posted January 6, 2005 thanks for the help unfortunately this did not help. the control terminals are in the event structure, and i dont need the value but only the event on the latching boolean (to start an action ...) the strange thing is: one of my former co-workers has build a large application (1000+ vis) based on subpanels / multiple event-structures and did never experience such problems. unfortunately i can't show him the code, because he is working for a competitor now. best regards, cb Quote Link to comment
Michael Aivaliotis Posted January 7, 2005 Report Share Posted January 7, 2005 First, please review this topic: http://forums.lavausergroup.org/index.php?showtopic=771 It contains recommendations for posting images to the LAVA Forums. It is not acceptable to post large images inside posts. -------- Now for your problem. You state the following: I have 2 booleans and a cluster of 6 booleans on the front panel of the main VI and the events on the single boolean controls are not recognized by the event structure after calling a "Sub-VI" with an event structure in it. Do you mean that if you do NOT call a "Sub-VI" with an event structure in it, everything works fine? Also I noticed this: I hope you are not splitting this reference. It is not recommended to split or share user events between event structures. Perhaps this is your problem. Quote Link to comment
i2dx Posted January 7, 2005 Author Report Share Posted January 7, 2005 Michael, sorry for the inconvenience with the large images. if you can manage that i will edit the original post and use attatchments. now i am unable to edit because you moved the topic ? ---- Do you mean that if you do NOT call a "Sub-VI" with an event structure in it, everything works fine? Exactly. This is the problem, and i can not figure out, why this happens. MY guess is, that i have found a very nasty bug in LV OR i am to stupid. In my experience strange behaviour like this (especially if you know that it is working in other projects) is either a very very very stupid bug in my software or a very nasty bug in LV ... You guess right, i do not split the user event. In fact i dont use it in this project. It's part of my project template and i did not remove the user event till yesterday, but that did not solve the problem anyway. finally i have removed the subpanel in this project and do it the "old style" with pop-up SubVIs, but i still would like to know what's went wrong ... best regards, cb Quote Link to comment
ad_dekkers Posted December 5, 2006 Report Share Posted December 5, 2006 Hi, I have the same problems. I know it's fixed in LV8, but we are still using 7.1. Is there already a LV7.1 bugfix/work around for this problem? Quote Link to comment
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.