Wednesday, March 9, 2016

C# kill specific process


  //Threading for speacific printer otherwise it will open default Faxman printer  
       Task.Factory.StartNew(() =>  
       {  
         Thread.Sleep(5000);  
         // Killing Process of default printer  
         Process[] processes = Process.GetProcessesByName("FaxManFMFFileCreator");  
         foreach (var process in processes)  
         {  
           process.Kill();  
         }  
       });  


Ensure that this project has Microsoft.Bcl.Build installed and packages.config is located next to the project file

In my Xamarin form application their was dependency Restclient on Microsoft.Bcl.Build Microsoft.Bcl. i just remove all using nuget and ...