LabWindows/CVI

cancel
Showing results for 
Search instead for 
Did you mean: 

How can i execute a DOS command (i.e dir) in LabWindow?

I tried to execute the following command :
system("dir") but LabWindow seems to not like it. Anybody have any idea how should i go about it? Thanx!
0 Kudos
Message 1 of 2
(2,974 Views)
DIR is an internal command, which means it's included in command.com, not in its own executable. system() is looking for an executable. So the correct syntax is
system("command.com /c dir");
Even under Windows 2000, sometimes it helps to remember some ancient DOS stuff.
0 Kudos
Message 2 of 2
(2,974 Views)