LabWindows/CVI

cancel
Showing results for 
Search instead for 
Did you mean: 

How do I make my panel visible again?

Hi.
I have created 3 panels and a use hidepanel function to hide a panel.Now when I tried to make that panel visible using displaypanel function it apair behind the active panel. How do I make it visible in front of my active panel?

Thanks.
0 Kudos
Message 1 of 3
(3,137 Views)
If you want to make the panel the active panel (and ipso facto come in front of all other panels) add SetActivePanel (HandleOfPanelToActivate) function to your code.

If you simply want to see the panel in front of the other even if it is not active you must set the "floating style" panel attribute to the desired behaviour.

Roberto


Proud to use LW/CVI from 3.1 on.

My contributions to the Developer Community
________________________________________
If I have helped you, why not giving me a kudos?
0 Kudos
Message 2 of 3
(3,137 Views)
DisplayPanel should make the displayed panel active. What is the relationship of the panels? How did you load and display the first panel? DisplayPanel or InstallPopup? Do you force a SetActivePanel after calling DisplayPanel?
The atached sample project has two panels with a button on panel1 to display panel2 and a button on panel2 to hide panel2. They share a callback function below. When DisplayPanel (panel2) is called, it is brought to the front and made the active panel. When HidePanel (panel2) is called, panel1 becomes active again.

case EVENT_COMMIT:
if (panel == PANEL1)
DisplayPanel (panel2);
else
HidePanel (panel2);
Message 3 of 3
(3,137 Views)