LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

How do I cause a vi to sent the contents of it's Front Panel Indicators out to STD OUT?

I inherited an intermixed bag of software tools that are called from Command Line Interfaces I would like to add some code that I have written in LabVIEW to this bag. The only problem I have at the moment is getting anything that looks like a standard output argument from LabVIEW.  Is this possible? For example lest say I have a vi that performs a number of tests based on input criteria at the completion of the tests the indicators on the front panel look like oh say,  a Boolean that says Pass, a string that says Unit Name, and an array of strings that holds the names of the tests run, and a numeric that indicates the number of tests performed. How can I pass these values to STD OUT?

 

0 Kudos
Message 1 of 5
(2,569 Views)
Do you know the command line parameters you can use a code interface node. You can try the system exec too.
0 Kudos
Message 2 of 5
(2,556 Views)
That's a great suggestion but it's inside out. Imagine if you will that the vi is now an executable and you want to call it from the System Exec vi.  How would you prepare the VI so that it can be called by the System Exec, i.e. pass variables to the vi's Controls, and returns it’s results, i.e. data in it's Indicators, so that the system exec can utilize them and pass them into the program.
0 Kudos
Message 3 of 5
(2,542 Views)
You could try wiebe's suggestion.
0 Kudos
Message 4 of 5
(2,536 Views)

an old thread I know but wanted to share this howto use a LabVIEW executable with SystemExec

 

- pass your command line arguments by using the LabVIEW Application Property Node App.Args

- write to std out using System.Console.WriteLine

- write to std err using System.Console.OpenStandardError (string2byteArray, see screenshot)

 

This solution is pure .net and works for 32 and 64bit systems.

std_out.jpg

0 Kudos
Message 5 of 5
(2,268 Views)