04-28-2022 09:22 AM
Hi guys,
I have a question about Tab Control. I show/hide tabs in my program when I log in/out.
When hiding the tabs, the right hand side border of the last tab, stays visible and it's driving me mad.
You can make it go away by either resizing the window, or making sure the last tab was selected during the time when hiding the tabs.
I mocked up two quick vi's to explain what I mean (LV2020). It happens on the deployment PCs too, so I know it'd not just some drivers on my own PC.
Is this a known bug? Is there an easier way, some option I'm not aware of? What do you guys think?
Thanks
Johnny
Solved! Go to Solution.
04-28-2022 10:35 AM
04-28-2022 10:56 AM
04-28-2022 11:21 AM
For simplicity and scalability, I would even eliminate the case structure and always do the workaround song&dance. Now and combination of visible pages will be treated the same.
04-29-2022 03:32 AM
Thanks for your reply, I'm glad I'm not the only one who sees that thing! Since I switched to Labview my pedantism is at an all-time high, I spend way too much time aligning various items, wires and paying attention to small things like this 😂.
Thanks for taking time to come up with another solution. I know a lot of people don't like timed/stacked sequences, but personally it gives me much less of a headache when trying to understand the flow. Your solution is much more sophisticated and well, you can see it all on one page!
Here's another way it can be done, by resizing the window and restoring it to its original size.
04-29-2022 11:51 AM - edited 04-29-2022 11:53 AM
The problem with stacked sequences is that in order to understand the flow, you need to constantly flip through the frames and and have a good enough short term memory to remember all other frames. 😄
All your value properties in frame=0 should be local variables.
Here's how you can do the same size twiddle with much less (and much cleaner!) code:
The problem with your code is still scalability because if you later decide to hide other adjacent or non-adjacent tabs, you would need to make changes all over the code. in my example, all you ever need is change the boolean diagram constant, assuming that tab 1 should always be visible (else we could even switch to the lowest visible tab with a little bit mode code). It is always a good thing to only have a single instance of the visibility loop. Half the code!! You can easily expand to have more than two visibility states, by just indexing into an array of booleans with the state variable.
05-03-2022 02:44 AM
Thanks for your help and all the input.