george seifert Posted September 26, 2007 Report Share Posted September 26, 2007 I need to shut down a while loop that contains an event structure in a subVI that runs parallel to my main VI. I know I've seen this somewhere, but am not quite sure what to search for. Just a quick refresher of my options would be most appreciated. I've done it with a named timed loop that I can stop from the main VI, but somehow that seems clumsy. George Quote Link to comment
ned Posted September 26, 2007 Report Share Posted September 26, 2007 QUOTE(george seifert @ Sep 25 2007, 08:53 AM) I need to shut down a while loop that contains an event structure in a subVI that runs parallel to my main VI.I know I've seen this somewhere, but am not quite sure what to search for. Just a quick refresher of my options would be most appreciated. I've done it with a named timed loop that I can stop from the main VI, but somehow that seems clumsy. George A good option here is to create a user event, register for it in your event structure, and trigger it in your main VI. It would look like this (simplified to one VI with two loops): http://lavag.org/old_files/monthly_09_2007/post-3989-1190733584.gif' target="_blank"> Alternatively, if you already have a timeout case in your event structure, you could check the state of a notifier in that timeout case to see if the notifier has fired. Quote Link to comment
george seifert Posted September 26, 2007 Author Report Share Posted September 26, 2007 QUOTE(ned @ Sep 25 2007, 10:08 AM) A good option here is to create a user event, register for it in your event structure, and trigger it in your main VI. It would look like this (simplified to one VI with two loops): http://lavag.org/old_files/monthly_09_2007/post-3989-1190733584.gif' target="_blank"> Alternatively, if you already have a timeout case in your event structure, you could check the state of a notifier in that timeout case to see if the notifier has fired. Perfect. Thanks. Quote Link to comment
MikaelH Posted September 27, 2007 Report Share Posted September 27, 2007 And don't forget to close the Event with "Unregister for Events" outside the lower while loop //Mikael 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.