private void VerificarConecao() { System.Threading.Thread.Sleep(5000); if (Directory.Exists("E:\\Rascal")) { Invoke((MethodInvoker) delegate { try { Funcionalidades.NovaAbertura(); } catch (Exception ex) { Console.WriteLine(ex.ToString()); Console.WriteLine(ex.Message); } CarregarINFOdisco(); CarregarEstatisticas(); }); } else { VerificarConecao(); } }
static void Main() { try { Funcionalidades.NovaAbertura(); } catch (Exception ex) { Console.WriteLine(ex.ToString()); Console.WriteLine(ex.Message); } Application.EnableVisualStyles(); Application.SetCompatibleTextRenderingDefault(false); Application.Run(new FormSeguranca()); }