title: Create a cmd window and write to it from C# application
body: <p>I am developing a C# component for Grasshopper for Rhino. As I am running some pretty heavy iterative analysis I would like to output results continuously to a cmd window just to make sure that the analysis is actually running.</p>
  
  <p>Here's what I tried:</p>
  
  <pre><code>using System.Diagnostics;
  
  
  Result results = new Result();
  Process cmd = new Process();
  cmd.StartInfo.FileName = "cmd.exe";
  cmd.StartInfo.RedirectStandardInput = true;
  cmd.StartInfo.RedirectStandardOutput = true;
  cmd.StartInfo.CreateNoWindow = false;
  cmd.StartInfo.UseShellExecute = false;
  cmd.Start();
  
  do {
      results = RunHeavyOperation(results);
      cmd.StandardInput.WriteLine("echo " + results.usefulInfo);
  } while (!results.conditionForEnd);
  
  cmd.WaitForExit();
  
  Result RunHeavyOperation(Result previousResults) {
      Result res = doHeavyStuff(previousResults);
      return res;
  }
  </code></pre>
  
  <p>I realise that I am missing part, but what is it?</p>