From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.
We appreciate your patience as we improve our online experience.
From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.
We appreciate your patience as we improve our online experience.
04-12-2012 09:08 AM
Hi,
I have one system with one tab control and working fine, but when i change the program and put two buttoms to change of tab the system is not working.
Can you help me please?
Attached the two programs.
Solved! Go to Solution.
04-12-2012 09:43 AM
What do you mean by "not working"? The next and prev buttons switch the tabs on my system.
What is the deal with the Numeric 2 local variable? It is right next to the terminal so you should just use a wire.
Also you might want to use a shift register for the tab page number. Here is a modified version.
04-12-2012 09:53 AM
Your basic fault is not really understanding how the event structure works. The event structure is the only thing running. If you were to add a timeout event, then the other code would periodically be polled and run.
Please, though, try to modify the code so that you do not use so many local variables. You can easily make a single control/indicator accessible on all of your tabs just by moving it onto the tab control with the cursor keys instead of the mouse. You get a shadow effect when the VI is idle but that disappears when it is running. Learn about shift registers.
04-12-2012 09:56 AM - edited 04-12-2012 09:57 AM
Hah, good point Dennis - I didn't even notice that and I added the shift register
But I was not really clear on what wasn't working. The OP said that it worked before he added the next and prev button. I didn't even notice till now that the original version didn't have an event structure.
04-12-2012 10:43 AM
Im sorry for my bad explain,
In withoutbutton you can check when i change the delay or number de led's in any tab's, the led's indicator in tab'2 change your value inmediately, and when i change the Enum in tab 1, the led indicator in tab 2 change automatic the working mode, and y can to change from one tab to other tab with the tab's on top of tab control, this is right.
The problem is when i want the same system but i need to change between tab's using push buttoms, in this case the function of push buttoms is right but the led's sequence in tab'2 only work one time and is stoped, this is the problem.
04-12-2012 10:55 AM
So, implement what I said.
04-12-2012 10:59 AM
Hi
I try to put a timeout event but i don't know how, i try to put a numeric constant input, but i don't know how to connect the wire inside of event structure and also how to create one new event to going out of evebt structure.
Rgds
04-12-2012 11:36 AM
You deleted the timeout event after you dropped it on the block diagram. Recreating it is no different than creating the value change events for the Booleans. You just select the Application as the event source.
I have no idea what you mean by a numeric constant or a wire inside the event structure. The only constant you need is a value wired to the timeout terminal and that is outside the structure.