Advertisement
Guest User

Untitled

a guest
Sep 17th, 2014
195
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.66 KB | None | 0 0
  1. private static void Process()
  2. {
  3. Process _process = new Process();
  4. _process.StartInfo.FileName = "C:\Windows\notepad.exe";
  5. _process.StartInfo.UseShellExecute = false;
  6. _process.StartInfo.RedirectStandardOutput = true;
  7.  
  8. // Start the process
  9. _process.Start();
  10. _process.BeginOutputReadLine();
  11.  
  12. Task task = Task.Factory.StartNew(() => MonitorProcess());
  13.  
  14.  
  15. Console.WriteLine("Main ");
  16. }
  17.  
  18. private static void MonitorProcess()
  19. {
  20. Console.WriteLine("Inside Monitor");
  21.  
  22. string x = null;
  23. x = x.Trim();
  24. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement