Starting a new process. : Process : Development C# Examples


C# Examples » Development » Process »

 

Starting a new process.









    
using  System;  
using  System.Diagnostics;  
  
class  MainClass  {    
    public  static  void  Main()  {    
        Process  newProc  =  Process.Start("wordpad.exe");  
  
        Console.WriteLine("New  process  started.");  
  
        newProc.WaitForExit();  
  
        newProc.Close();  //  free  resources  
  
        Console.WriteLine("New  process  ended.");  
    }    
}
    
   
  
   



Output

New process started.
New process ended.


HTML code for linking to this page:

Follow Navioo On Twitter

C# Examples

 Navioo Development
» Process