12-22-2008 05:31 AM
Hi
1.I want to value signal a menu selection(user) event in the first frame of sequence structure,a vi and its run time menu is attached.kindly solve my problem.
2.can we use set menu item info function in an event other then menu selection(user).
Thanks
Solved! Go to Solution.
12-22-2008 07:06 AM - edited 12-22-2008 07:07 AM
You can't programmatically trigger menu selection event, they can only be triggered by menu selections. If you want something to happen in response to a data input you need to use a user event. Now if that operation happen to be the same thing as a menu selection, you have two options. You can either duplicate the code in both the menu selection and the user event (not a good idea) or have the code that performs the action in the user event and have the menu selection also fire the user event.
Mike...
PS: You mention sequence structures. I haven't looked at you code but I can tell you that well-designed code never needs a sequence structure. In fact sequence structures add unnecessary complication and increase the liklihood of errors and inefficiency.
12-22-2008 07:28 AM - edited 12-22-2008 07:29 AM
If you want to execute that code unconditionally as a first step, you don't need an event structure. That would make no sense at all, just do the following:
Just use plain old dataflow instead of a sequence. Use the error out to enforce execution order (not shown).
(btw: your file question.zip is not a zip file. To open it, we need to rename it to question.rar first. Is there a reason why you changed the extension???)