LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

how to substitute main VI front panel for sub VI panel

I have a instrument that runs a number of different process control sequences.  I have a large number of boolean controls and indicators that are different between sequences.  To handle this I used sub-VI that opens a new popup  front panel when called.  I just hate seeing all the front panels in my taskbar.  How can I just redraw or substitute the main VI front panel for the sub-VI front panels?  I know it can be done, I just can't figure out where to get started at.  I have attached a simple example of what I am currently using.

 

Thanks for the help.

 

Danny

Danny
Download All
0 Kudos
Message 1 of 7
(2,675 Views)

Look at tab controls.

 

Look at subpanels.

 

One of these may do what you want.

 

Lynn

0 Kudos
Message 2 of 7
(2,672 Views)

Hi,

 using the property of front panel, you can hide or unhide the vi's. hide the vi which is calling the sub vi and after the execution of the sub vi unhide the previous vi..

check out the below example.. probably this will help ur purpose...

LV 8.0, 8.6, 2011,2012,2013 WinXP
Download All
0 Kudos
Message 3 of 7
(2,663 Views)

Lynn,

 

I have used tab controls and that is not what i'm really looking for.  subpanels sounds more like what i'm looking for.  I'll do some more reading on the subpanels.  

 

Thanks for the help.

Danny
0 Kudos
Message 4 of 7
(2,646 Views)

Sub panel is what you're looking for, but if you have a decently low number of sub-vi's (<15?) you can use a tab control and paint it transparent. Just place a sub-vi in each and change the tab page to see them. 🙂

 

/Y

G# - Award winning reference based OOP for LV, for free! - Qestit VIPM GitHub

Qestit Systems
Certified-LabVIEW-Developer
0 Kudos
Message 5 of 7
(2,634 Views)

The "Docking" code I posted in this thread may be of interest.

 

Screenshots of it in action can be found in this image albumn.

 

Ben

 

Retired Senior Automation Systems Architect with Data Science Automation LabVIEW Champion Knight of NI and Prepper LinkedIn Profile YouTube Channel
0 Kudos
Message 6 of 7
(2,622 Views)

I am finally able to get back to working on learning about subpanels.  After doing a lot of reading and looking at example, subpanels are what i'm looking for.  I have been playing around with a very simple example trying to better understand it.  What I am hoping to do is move away from using tabs and go to a ring enum to allow the user to select the test they wish to run and then the subpanel will populate with all the controls necessary for that testing proceedure.  most everything I do gets deployed onto a real-time compact fieldpoint system to connect to the instrument.  This is the reason i'm not using event structures, because I don't believe they will not  work when deployed to the target.

 

Do I have the subpanel configured anywhere close to correct?  The VI works but the subVI doens't end correctly.  I have to hit the stop button in the subpanel twice to get it to end.   I haven't added anymore subVI to the other states for this reason.  What is the correct way to stop the subVi so another subVI could be launched? Also I tried to move the subpanel invoke method out of the case structure but didn't know what to wire the VI reference to If I didn't have a subVI in one of the cases.  I'm sure there is a more elegant to handle this instead of using a state machine.

 

Thank you for the help.

 

Danny

 

Danny
Download All
0 Kudos
Message 7 of 7
(2,571 Views)