[Mono-winforms-list] How to run commands from mono C#
Baltasar García Perez-Schofield
baltasarq at gmail.com
Wed Dec 4 12:05:46 UTC 2013
Hi,
> How to run commands from terminal in mono C#.
> p = new Process();
> p.StartInfo.FileName = @"#!/bin/sh\n";
> p.StartInfo.UseShellExecute = false;
> p.StartInfo.RedirectStandardInput = true;
> p.StartInfo.RedirectStandardOutput = true;
> p.StartInfo.RedirectStandardError = true;
> p.StartInfo.CreateNoWindow = true;
> p.Start();
I don't see what this has to do with WinForms, but in any case, you should probably begin changing p.StartInfo.FileName = @"#!/bin/sh\n"; with just p.StartInfo.FileName = @"/bin/sh";
--
Baltasar (baltasarq at gmail.com http://baltasarq.info/)
More information about the Mono-winforms-list
mailing list