LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

control .exe with separate vi

Hi,

 

I have a rather large .exe that was designed in LabVIEW (2009).  The .exe has a boolean start/stop to begin the simulation.  I'd like to create a separate vi that can drive this start/stop switch without having to rebuild the .exe with new code.  Basically, I want to start the simulation, wait some time, then stop the simulation, wait some time, repeat n iterations.

 

Any advice would be great.

Thanks.

0 Kudos
Message 1 of 4
(2,402 Views)

Hi michaelbails,

  While building any LabVIEW exe,an option should be set/checked in MyAPPLICATION PROPERTIES/advanced section to allow the exe to accept all the parameters in a command line.If that is the case we can call that exe using system exec.vi and pass the parameters from another vi.If it wont accept any command line,then you can call the exe but you cant pass any command line from another VI.

 

 

Thanks and regards,

srikrishnaNF

Regards,
Srikrishna


0 Kudos
Message 2 of 4
(2,395 Views)

Hi,

 

Thanks for the reply.  The LabView exe already exists (I didn't build it), but I want to drive an on/off switch.  Maybe I'm a bit confused by your response.  Could you elaborate a bit more.

 

Thanks in advanced.

 

Mike

0 Kudos
Message 3 of 4
(2,384 Views)

You would need to use the VI Server to do this. You will have to add a couple of lines to the application's .ini file to set the VI server port. You want to make this different from LabVIEW. In your VI you can open an application reference and then open a VI reference. See attached example.

Message 4 of 4
(2,379 Views)