LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Bug in Event Case using a three or more pages tab controll?

Hi,
I have a problem with event structures using a tab controll with LabVIEW6.1. I have a three pages tab controll. For better overview in the block diagram I use a case structure, which is connected to the tab controll terminal. In each page of the case structure I put an event case for executing my front panel commands (a while loop is the outermost structure). In every event case I added the event "tab controll: value changed" for switching from one page to another. But this blocks the front panel completly.

The problem seems to be, that in the following cycle of the while loop, the the event case for the chosen page of the tab controll is triggered by the value changed event, too!

I d'ont kno
w, why this happens. I think, I d'ont use the event cases in a wrong way. For a better understanding I attached an example VI, where I programmed the above decribed structure.

Could this be a bug? If yes, when will it be fixed?
0 Kudos
Message 1 of 6
(2,911 Views)
Try this. It is a little more straight forward.
Also, if you decide to change what a case does, you only do it in one spot.
Message 2 of 6
(2,911 Views)
There is a section in the on-line help about Event structures called "Caveats and Recommendations when Using Events in LabVIEW". In there, there is another section called "Avoid Placing Two Event Structures in One Loop". The problem that you're seeing is specifically addressed here. It is not a bug but the way that the event structure is designed.
0 Kudos
Message 3 of 6
(2,911 Views)
Hi Dennis,
I always thought, that the help section you mentioned is for two event structures placed parallel in one loop, which is not true in my case. Also, when I change the page of the tab controll, the event structure of the old page executes, then the while loop reiterates, then the event structure of the new page executes, too! I think, this behavior is different from the one described in the mentioned help section, but I can be wrong: English is not my native language.

I'm not happy about "gbush" proposed solution (se attached VI), because when I handle every Event in one big event structure, there will be a lot of events. I can't say yet, how many events, but certainly over 20! But if thre is no other solution, well, than this is my pr
oblem.

Thanks for your help.
0 Kudos
Message 4 of 6
(2,911 Views)
20 events is not a large number to handle. Some of my programs handle this many on a regular basis with no problems at all. I think it's the best solution right now.
0 Kudos
Message 5 of 6
(2,911 Views)
You are right. I programmed today a little bit (12 events and growing...) and it still looks good and clearly arranged. Thanks for your help.
0 Kudos
Message 6 of 6
(2,911 Views)