public void Stop() { Worker.CancelAsync(); if (StartedProcess != null) { StartedProcess.Kill(); } }
static void Main(string[] args) { Console.Title = "Started Process"; StartedProcess sp = new StartedProcess(); sp.showCommandLine(args); sp.makeSound(); for(int i=0; i<10; ++i) { Console.Write("\n running"); Thread.Sleep(500); } Console.Write("\n -- press key to exit: "); Console.ReadKey(); }