static void Main() { Application.EnableVisualStyles(); Application.SetCompatibleTextRenderingDefault(false); using (var frm = new frmMain2()) { frm.ShowDialog(); } }