02-17-2023 03:28 PM
Referring to picture in attachment.
Part of my main VI is used to select an instrument config file then use info in the file to program multiple power supplies at multiple GPIB addresses with various voltage settings.
The config file contains power supply names and voltage settings, it does not contain GPIB address info which varies from test setup to test setup.
I'd like to be able to select the config file then press a button which executes part of the VI which scans the file and extracts power supply names, voltage settings, etc. It then would also populate the string array called "Supply Name 2" in picture. Then I can select the appropriate VISA resource (GPIB address) for each line in Supply Name column. Afterwards, I would like to run the Mian VI (the reset of the code) in same front panel which will program the actual power supply instruments. So how do I execute a section of my VI code using a button called "Load Config File" and retain the info from the config file to be used with rest of VI code upon clicking the normal "Run VI" button?
Solved! Go to Solution.
02-17-2023 03:57 PM - edited 02-17-2023 03:58 PM
Hi Todd,
@Todd_Cooper wrote:
So how do I execute a section of my VI code using a button called "Load Config File" and retain the info from the config file to be used with rest of VI code upon clicking the normal "Run VI" button?
You cannot execute code before starting the VI using the run button!
Instead your VI need to run as long as needed...
(Do you need to run Word twice to be able to edit a document?)
02-17-2023 04:29 PM
Ok thank you for your input.
Todd