LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

How to set LAST used values as default

Hi,
To run my application,I usually want to set the most of the parameter values same as used in last experiment. I do not want to set the default values manually as I had to use three codes and there would be 20+ controls in all these.
(Sorry Evan, I tried to use your code. But it was not very helpful)
Thanks,
Dushyant
0 Kudos
Message 1 of 8
(3,206 Views)
See reply here.

Curious: does anyone have a usability explanation for why we see so many duplicate posts?

Dushyant, do you recall why you ended up posting the same question three times--was it because you didn't immediately see your post appear, or something else? Maybe this has already been discussed, but it would be nice if we could identify some usability improvements that could cut down on the number of duplicate posts we see, even if it's something as simple as bold, red, expectation-setting text that appears immediately when you post.

--John
0 Kudos
Message 2 of 8
(3,185 Views)
You can "make current values default" with this option in "operate" menu. Then next time you will get this values.
You can make that on-line using "Invoke node" on VI.
I append an example but it doesn't run becase you must insert it in your VI.
0 Kudos
Message 3 of 8
(3,170 Views)
Thanks Perro.

I have tried to do as syou suggested. However, when I tried to run, it was getting intialized to zero. Would you please have a look and modify the attached file.

Sorry, I ended up pasting the similar messages more than once. I could not use effectively the suggestion given by Evan for my first message and he could not sort it out either. This makes me paste second message. Later on, I tried to edit that and ended up pasting it again. Sorry again.
0 Kudos
Message 4 of 8
(3,152 Views)
I can't open your VI because it's on 7.1 LabView Version.
But I will explain you how to make it.

1.-Set all controls with your desired values (You can make it online or offline).
2.-Use the function:
- Operate/Make current values default (offline mode)
- Use a method: Insert an "Invoke node" & select "VI server class" as VI (not appliction). Then select the method: "Make current values default "

3.-Every time you open your .vi the values will be these. or when you want reinit your control to this value run the method "Reinitialize all to default".

I hope you can solve your problems with that...
0 Kudos
Message 5 of 8
(3,111 Views)
why not save to and load from some kind of config file?
0 Kudos
Message 6 of 8
(3,109 Views)
You can save that values in a config file using "configuration files VI" (it's in "File I/O") or saving values in a spreadsheet. However this solution is large to program and you must make a register for every control so this solution serves only for one application.
0 Kudos
Message 7 of 8
(3,100 Views)
Thanks a lot guys,
I was able to resolve the issue.
0 Kudos
Message 8 of 8
(3,085 Views)