static void Main(string[] args) { Thread.Sleep(10000); Mydetector mydetector = new Mydetector(); mydetector.Start(); Console.ReadLine(); }