I want to send and receive commands like "dir" and so on but i can't manage to read the output
+3
A:
You have to redirect std in and std out. Once you do that, in C#, use the console as you would if you were writing a console app.
http://msdn.microsoft.com/en-us/library/3x859hf2(vs.71).aspx
Gabriel McAdams
2010-04-09 17:15:03
+1
A:
You should not use console commands from code unless you really need to. (Hint: You don't)
You're looking for Directory.GetFiles
.
SLaks
2010-04-09 17:15:47
+1
A:
If you are trying to execute an external application and capture the output you should look at this. The System.IO namespace has Directory, File, and Path classed which avoid the need to use external applications to enumerate directories.
BrianLy
2010-04-09 17:16:42
thanks, that was just an example :D
2010-04-09 17:18:29
thanks i found out :)
2010-04-09 17:30:21