private void ContinueStartUp() { if (_notification != null) { _notification.Close(); } new Thread(CheckDatabaseConnection).Start(); }
private void ServiceStopThreadStart(object threadObject) { var thread = threadObject as Thread; if (thread == null) { return; } VistaSecurity.RestartElevated("/STOPSQL", true); Thread.Sleep(500); Dispatcher.Invoke((Action)(() => { _notification.Close(); if (!ServiceHelper.IsSqlBrowserServiceRunningLocally) { App.SwitchToDefaultDesktopOnClose = true; App.ShutdownApplication(); } else { Window window = Window.GetWindow(this); if (window != null) { window.Close(); } } })); thread.Abort(); }
public void PrintRegisterReport(RegisterDrawer drawer) { ActionNotificationControl notification = ActionNotificationControl.Create(MainWindow.Singleton, Types.Strings.RegisterMenuPreparingReport, Types.Strings.Notification); notification.Show(); notification.ParentWindow.Closed += Notification_Closed; ReportManager.PrintRegisterReport(drawer, ParentWindow_Closed); notification.Close(); }