LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

How can I reset my VI to default values when I stop it ?

Solved!
Go to solution

Hello,

 

I have a VI with changing values when I click on start the value start with the defauts values, but when I stop my VI and I want to restart it the values are the last values in memories before I stop the VI, to solve it's problem I close my VI and I open again the program... it's not fun...

 

I would know if it exist a method to do this automatically, like if I click on the edit menu on "put in defauts values"...

 

Bye.

0 Kudos
Message 1 of 5
(11,908 Views)
Solution
Accepted by topic author leo2b

Hi leo2b,

you can use the "Resettodefault" method at the end of your vi.

See the attached example.

 

Mike

Message 2 of 5
(11,904 Views)

Mike's suggestion is best.

 

If the 'start value' needs to change, you could use local variables to set the initial values.  But, this is not the preferred method.

>

"There is a God shaped vacuum in the heart of every man which cannot be filled by any created thing, but only by God, the Creator, made known through Jesus." - Blaise Pascal
0 Kudos
Message 3 of 5
(11,902 Views)

One way is Edit -> Renitialise values to default

 

Keyboard shortcut in 8.2 is Alt E Z

 

It can also be done programmatically;

From the Application Control pane, drop "Vi server reference" - it will show as This Vi,

Drop an invoke node from the same pane, and wire the server reference to the reference input, and set the method to Default values . reinitialise all to default.

 

 

Rod.

 

Message 4 of 5
(11,898 Views)

Thank you for your responses I will try your methods.

 

bye

Message Edité par leo2b le 07-24-2009 09:21 AM
0 Kudos
Message 5 of 5
(11,885 Views)