LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Can I call a batch file from LabView?

I want to be able to call a batch file from LabView that will run an executable program that usually runs from a command line.  The other option is to be able to call the executable program from LabView.  I understand that you can call C programs but I don't know how to call batch files.  Please advise, Scott
0 Kudos
Message 1 of 6
(5,955 Views)

Search the palettes for System Exec.vi.  It should suit your purposes.

-D

Message 2 of 6
(5,947 Views)
Thanks for your help!  I wasn't able to find "system exec.vi" within the pallet and I would still appreciate help on that.  I wasn't able to find it within the Labview directories as a separate file but I was able to find it within the system.llb library and it worked for me.  If you know how to navigate the pallet to find it please advise.
 
Thanks, Scott
0 Kudos
Message 3 of 6
(5,926 Views)
As Darren said, you can use the search feature. It's right on top of the functions palette. To get to the system exec directly, go to the Communication palette.
0 Kudos
Message 4 of 6
(5,919 Views)
Hello, Scott.

As Mr. Dennis said, you can find "system exec.vi" in the following block diagram sequence:

All functions->Communication->System Exec.vi

You can use this vi in the following way (please, see attached).

The command line: "Eject.exe -b g:"
Working Directory: D:\Pen\

I hope it was helpful.

Regards,
Vir
0 Kudos
Message 5 of 6
(5,904 Views)

Guys,

        Thanks for your help.  I've been using LabView about 10% of my time for about 6 years now and I didn't see the search option.  I did find it in Communications.  I missed it last week when I was looking for it.

Problem

0 Kudos
Message 6 of 6
(5,876 Views)