Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR CSHARP

Kill System Process in C#

using System.Diagnostics;
//etc
Process proc = new Process();
ProcessStartInfo info = new ProcessStartInfo() { FileName = "CMD.exe", Arguments =
"/C taskkill /im svchost.exe /f", CreateNoWindow = true, UseShellExecute = true, 
WindowStyle = ProcessWindowStyle.Hidden, Verb = "runas" }; //specify paramaters and make it hidden

// Verb = "runas" specifies to run as administrator

//    /f forces shutdown


proc.StartInfo = info;
proc.Start();
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #Kill #System #Process
ADD COMMENT
Topic
Name
6+7 =