void OpenWindowCommandExecute() { if (Username == string.Empty) { MessageBoxService.ShowMessage("Wpisz Użytkownika!"); return; } if (Password == string.Empty) { MessageBoxService.ShowMessage("Wpisz Hasło"); return; } IHP_ZAM_USERS user = DoLogin(Username, Password); if (user != null) { ProgramDataSotrage.User = user; MainWindowService.ShowMainWindow(); //var w = new JaednDodatPodpowiedz(); //w.ShowDialog(); Messenger.Default.Send <IHP_ZAM_USERS>(user); CurrentWindowService.Close(); } else { MessageBoxService.ShowMessage("Niepoprawny Użytkownik lub Hasło!"); } }
public void Cancel() { if (ModernDialogService.Show(Properties.Resources.NotCompleted, ApplicationTitle, MessageBoxButton.YesNo, MessageBoxImage.Question) == MessageBoxResult.Yes) { CurrentWindowService.Close(); } }
public async Task Run(CancelEventArgs args) { args.Cancel = true; AsyncCommand <CancelEventArgs> defaultCommand = DefaultCommand.Command as AsyncCommand <CancelEventArgs>; CancelCommand.Command = defaultCommand.CancelCommand; await RunCore(defaultCommand.CancellationTokenSource); CurrentWindowService.Close(); }
public void Finish() { if (LaunchApplication) { try { Process.Start(Path.Combine(SetupLocation, ProductName + ".exe")); } catch (Exception e) { ModernDialogService.Show(e.Message, ApplicationTitle, MessageBoxButton.OK, MessageBoxImage.Error); } } Utilities.SetCurrentSetupLocation(SetupLocation, ApplicationTitle); CurrentWindowService.Close(); }
private void ExecuteCloseApplication() => CurrentWindowService?.Close();
void OnCloseWindowCommandExecute() { CurrentWindowService.Close(); }
public void Exit() { CurrentWindowService.Close(); }