Apoorv Khurasia wrote:
I am trying to build a system information utilty in C#. I want to use some
of the command line features e.g. @systeminfo and @find etc. How can I use
them in Visual C#?
Create a new ProcessStartInfo object, fill in the appropriate
properties, then pass it to Process.Start. If you don't need the more
advanced members, you can just call one of the other overloads of
Process.Start.
You may want to redirect input or output, so you'll probably want to
turn off UseShellExecute and set RedirectStandard* as appropriate. The
Process class then has the StandardInput etc. that you can use.
-- Barry
--
http://barrkel.blogspot.com/