LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Running a Command in CMD vs LabVIEW System exec

I usually use something like 

cmd /s /c "ticcmd --home fwd"

if my command that I would type into cmd is

ticcmd --home fwd

 

If you have quotes, the /s handles that too (so you could do)

cmd /s /c "mycommand_that_accepts_paths "C:\Program Files\Some Junk With Spaces\a.txt" "C:\Source\Other space filled path.txt""

noting the nested quotation marks...

 

As aputman said, this should all go in the command line input - not the standard input input.


GCentral
0 Kudos
Message 11 of 12
(741 Views)

Hi JScherer,

In your  command structure "ticcmd --home fwd" ,"ticcmcd" is the actual command and '--home fwd' are the arguments.

Hence while executing this command ,you need to pass the absolute path of 'ticcmd.exe' (unless added to PATH variable) along with 'cmd /c' to the 'command line' terminal and then pass the arguments "--home fwd" to 'Standard Input'  terminal of the 'System Exec.vi' function.

 

If this way doesn't work, then try creating a batch file including that command and try to run using 'System Exec.vi' by passing the batch file to the 'command line' terminal.

 

Regards,
Srikrishna


0 Kudos
Message 12 of 12
(739 Views)