From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.

We appreciate your patience as we improve our online experience.

LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

How to hide a control and change a background image SIMULTANEOUSLY

Solved!
Go to solution

Hi,

 

I have made a slideshow VI on LabView that also monitors real-time data from a datalogger.

 

The program works like this: - 

 

Startup/Page 1: - Background pane displays a nice screenshot. A set of indicators displays real-time data. Switches to Page 2 after 20 seconds.

Page 2: - Background changes to another screenshot. Real-time indicators hide, and a set of three graphs show up, displaying historical data. Switches after 20s.

Page 3 etc: - Graphs and indicators hide, a 'slideshow' is displayed by changing the background pane. Switches back to page 1 after sequence.

 

Everything works nicely, except for one thing: I cannot get the indicators to hide and background to change simultaneously, resulting in an awkward 'lag' in between.

 

I did an example VI to illustrate this. Simply select two separate pictures at the front panel, run the VI and toggle the Boolean control to see what i mean.

 

Any idea of how to get the indicators and background to change simultaneously?

 

Thanks in advance,

Jin

0 Kudos
Message 1 of 4
(2,565 Views)
Solution
Accepted by Jin1987

Hi Jin,

 

did you try to "DeferPanelUpdates" when doing the switching? It's a property of the pane...

 

So set Defer=TRUE, do all the switching, set Defer back to FALSE!

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
Message 2 of 4
(2,555 Views)

I would use a tab control and pictures. I would preload the pictures and put the controls on the different pages. See the attached code.

Tim
GHSP
0 Kudos
Message 3 of 4
(2,520 Views)

Brilliant, thanks!

0 Kudos
Message 4 of 4
(2,496 Views)