07-13-2021 10:20 PM
Hello LabVIEW Enthusiast,
I'm using Tab control (multiple) and there are some controls over there. What I'm trying to do is:
The same control will be available in the different tab and if in one place control value changes another tab's control value will be updated with the same value.
For easy demonstration I'm giving an example:
Here, Firstly Input 1 should be available in the page 2 tab, and then if I change the Input 1 value from page 2, page 1 Input 1 value will also change. So Input 1 control value should be the same on page 1 and page 2 tab.
Snipped also attached if you need to change in this example.
Appreciate your kind help.
- Reduanul
Solved! Go to Solution.
07-14-2021 12:46 AM - edited 07-14-2021 12:48 AM
Hi Reduanul,
@REDUANUL wrote:
What I'm trying to do is:The same control will be available in the different tab and if in one place control value changes another tab's control value will be updated with the same value.
When the control should be visible on all tabs then you need to place that control over the tab container, but not inside the tab container!
@REDUANUL wrote:
Snipped also attached if you need to change in this example.
You didn't attach a snippet, but an ordinary image. This is quite a difference in LabVIEW! (Please read the LabVIEW help for snippets!)
07-14-2021 05:01 AM
Thanks, GerdW it's working 🙂
Now is it possible to get rid of the black border color at edit time?
Then can I make control visibility on selective tabs instead of all? (e.g only on tabs 1 and 2 whereas I've 3 tabs and on tab 3 it will not be visible)
Like this:
Last time as I said I uploaded a snippet that will work if you drag that image to the block diagram. I've checked it worked 🙂
However, this one is the updated snippet for the above case.
- Reduanul
07-14-2021 05:58 AM
Hi Reduanul,
@REDUANUL wrote:
Now is it possible to get rid of the black border color at edit time?
Then can I make control visibility on selective tabs instead of all? (e.g only on tabs 1 and 2 whereas I've 3 tabs and on tab 3 it will not be visible)
The black border will always be visible at edit time.
To control visibility programmatically you can use property nodes for that FP element…
@REDUANUL wrote:
Last time as I said I uploaded a snippet that will work if you drag that image to the block diagram. I've checked it worked 🙂
I'm sorry, I didn't check the attachment. I just saw the image in the message text.
On your snippet: why is there no label at the tab terminal?
07-14-2021 07:08 AM
Hello GerdW,
@GerdW wrote:The black border will always be visible at edit time.
It will be also possible to remove the black border invisible at edit time (I tried and it works). For this you just need to put the control on a flat box like this:
Thanks for your awesome help 🙂
07-14-2021 07:11 AM - edited 07-14-2021 07:12 AM
Hi Reduanul,
@REDUANUL wrote:
It will be also possible to remove the black border invisible at edit time (I tried and it works). For this you just need to put the control on a flat box like this:
What's the point to put more stuff on the frontpanel than needed?
Your users will never see the black border as they only see the frontpanel at runtime. That border is just a visual reminder to you (as the programmer) that this control hovers over the tab container…
07-14-2021 08:36 AM
Hello GerdW,
@GerdW wrote:What's the point to put more stuff on the frontpanel than needed?
Yes, that true but I did for looking visually clean.
Another thing I forgot to ask is there any way to do this? :
When I exit the program then Input Button 1 will be visible on Page 1 and on Page 2 it will remain as invisible?
I tried with the property node but did not work. In all tabs, it remains either visible or invisible.
- Reduanul
07-14-2021 12:44 PM
Hi Reduanul,
@REDUANUL wrote:
Another thing I forgot to ask is there any way to do this? :
When I exit the program then Input Button 1 will be visible on Page 1 and on Page 2 it will remain as invisible?
I tried with the property node but did not work. In all tabs, it remains either visible or invisible.
When the VI has stopped then the code in the block diagram cannot react to user actions anymore: the last visibility setting will stay active until you run the VI again…
As I said before: your users will never see the frontpanel at edit time - so what's the problem?