public void Signout() { YellowstonePathology.YpiConnect.Contract.Identity.ApplicationIdentity.SignOut(); this.m_ClientServicesUI.SignOutButtonVisibility = System.Windows.Visibility.Collapsed; this.m_ClientServicesUI.DisplayName = string.Empty; SignOutPage signOutPage = new SignOutPage(); this.MainFrame.NavigationService.Navigate(signOutPage); foreach (Window window in Application.Current.Windows) { if (window != Application.Current.MainWindow) { window.Close(); } } }