LabWindows/CVI

cancel
Showing results for 
Search instead for 
Did you mean: 

Start second window in command line application

Solved!
Go to solution

I have a vantage CVI command line application. The code reads a module using can protocol. It then takes this information and generates a product label and places it on a module, scans the bar-code, and verifies it's accuracy and ejects it from the fixture. This process involves a DAQ and a PLC. Lately we have been having issues with the PLC and DAQ. I want to start a second window and display the state of the DAQ i/o lines. Starting the second thread is no problem, What I need to know is how to fire off the second display window. I am trying to avoid using the GUI window features if I can. Is this possible and where can I find an example of this ?

0 Kudos
Message 1 of 2
(2,980 Views)
Solution
Accepted by topic author Rich_G

Hello Rich_G,

 

Unfortunately, Win32 programs are limited to one console per process.  You will either need to display your status information in a GUI, or create a child process to host your second console. 

 

An example of creating a child process and communicating with it via named pipes can be found here.  It's in C++, but it should translate pretty directly to C.  While the example makes use of named pipes to do the interprocess communication, you could use any mechanism you prefer, such as Network Variables.


NickB

National Instruments

0 Kudos
Message 2 of 2
(2,973 Views)