static void Main() { // 检测更新 AU.Updater updater = new AU.Updater(); if (updater.NeedUpdate()) { Process.Start("AutoUpdater.exe"); Environment.Exit(0); } // BasisPlatform:应用程序初始化 Basiser basiser = Basiser.GetInstance(); basiser.Init(ClientConfiguration.Instance.AppIdentifier, PlatformType.Winform, IPAddress.Parse("127.0.0.1"), 0); Application.EnableVisualStyles(); Application.SetCompatibleTextRenderingDefault(false); bool notRun; //using (Mutex mutex = new Mutex(true, Application.ProductName, out notRun)) //{ // if (notRun) Application.Run(new FrmWin()); //else //MessageBox.Show("程序正在运行", "提示", MessageBoxButtons.OK, MessageBoxIcon.Information); //} }
static void Main() { // BasisPlatform:应用程序初始化 Basiser basiser = Basiser.GetInstance(); basiser.Init(ADGSAppConfig.GetInstance().AppIdentifier, PlatformType.Winform, IPAddress.Parse("127.0.0.1"), 0); Application.EnableVisualStyles(); Application.SetCompatibleTextRenderingDefault(false); Application.ThreadException += new ThreadExceptionEventHandler(Application_ThreadException); bool notRun; using (Mutex mutex = new Mutex(true, Application.ProductName, out notRun)) { if (notRun) { Application.Run(new Form1()); } else { MessageBox.Show("程序正在运行", "提示", MessageBoxButtons.OK, MessageBoxIcon.Information); } } }
static void Main() { // BasisPlatform:应用程序初始化 Basiser basiser = Basiser.GetInstance(); basiser.Init(CommonAppConfig.GetInstance().AppIdentifier, PlatformType.Winform, IPAddress.Parse("127.0.0.1"), 0); Application.EnableVisualStyles(); Application.SetCompatibleTextRenderingDefault(false); DotNetBarUtil.InitLocalization(); Application.Run(new MDIParent1()); }