LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

How to get in Labview the same effect that in LabWindows/CVI with RecallPanelState/SavePanelState?

Hello,

I consulted with one of my colleagues here at NI (a Measurement Studio specialist), and he told me that these functions in CVI will read a panel state from a file you previously created with SavePanelState. If the panel is currently visible, all controls are updated to reflect their new states.

Unfortunately there is no way to do this directly in LabVIEW. However, there are a few indirect ways to accomplish this goal. First, you can use VI Server to call the "Make Current Values Default" and "Reinitalize All to Default" methods on your VI programmatically. This would allow you to "save" all the front panel objects as defaults, then "reset" them all to those default values whenever you desire.

Another thing you can do is programmatically save all your fr
ont panel values to a global variable. Later, you can read from that global variable and write all the values stored there into your front panel objects.

I will submit a suggestion to R&D that they look to include this functionality in a future version of LabVIEW.

I hope these suggestions help. Good luck with your application, and have a pleasant day.

Sincerely,

Darren Nattinger
Applications Engineer
National Instruments
Message 2 of 3
(2,569 Views)
Sounds like a great idea.

the problem with "Make Current Values Default" is that I thought it was only
available in the development environment, and not in a compiled .exe. Does
this work in a compiled program?

Shane

Darren schrieb in Nachricht
<50650000000500000029290000-986697009000@quiq.com>...
>Hello,
>
>I consulted with one of my colleagues here at NI (a Measurement Studio
>specialist), and he told me that these functions in CVI will read a
>panel state from a file you previously created with SavePanelState. If
>the panel is currently visible, all controls are updated to reflect
>their new states.
>
>Unfortunately there is no way to do this directly in LabVIEW.
>However, there are a few indirect ways to accomplish this goal.
>First, you can use VI Server
to call the "Make Current Values Default"
>and "Reinitalize All to Default" methods on your VI programmatically.
>This would allow you to "save" all the front panel objects as
>defaults, then "reset" them all to those default values whenever you
>desire.
>
>Another thing you can do is programmatically save all your front panel
>values to a global variable. Later, you can read from that global
>variable and write all the values stored there into your front panel
>objects.
>
>I will submit a suggestion to R&D that they look to include this
>functionality in a future version of LabVIEW.
>
>I hope these suggestions help. Good luck with your application, and
>have a pleasant day.
>
>Sincerely,
>
>Darren Nattinger
>Applications Engineer
>National Instruments
Using LV 6.1 and 8.2.1 on W2k (SP4) and WXP (SP2)
0 Kudos
Message 3 of 3
(2,569 Views)