Execute shell without .cmd file?

FuturShoc

Active member
Joined
Jul 28, 2006
Messages
27
Location
Hot Springs, Arkansas
Programming Experience
3-5
I would like to be able to issue a command to the shell, but I find having to write my command out to a .cmd file first to me rather tedious.

Is it possible to simply run a shell command directly from within .NET without having to generate the .cmd file first and then executing that file?
 
You can run executable commands with the Process class. Internal shell commands like "DIR" have to be passed as parameters to Cmd.exe using the "/c" switch.
 
Back
Top