private void BtnSearch_Click(object sender, RoutedEventArgs e) { if (string.IsNullOrEmpty(viewModel.Platform)) { return; } if (string.IsNullOrEmpty(viewModel.PlayerName)) { return; } if (controller.GetPlayer(viewModel.Platform, viewModel.PlayerName)) { //MessageBox.Show("OK"); ProfileWindow profile = new ProfileWindow(); profile.Show(); this.Close(); } else { MessageBox.Show("Player not found"); } }