private void logOutLabel_MouseLeftButtonUp(object sender, MouseButtonEventArgs e) { var lastWin = App.Current.MainWindow; var win = new EntryWindow(); App.Current.MainWindow = win; App.Current.MainWindow.Show(); lastWin.Close(); App.Current.MainWindow.Content = new EntryWindow().Content; }
void System.Windows.Markup.IComponentConnector.Connect(int connectionId, object target) { switch (connectionId) { case 1: this.entryWindow = ((CourseWork.EntryWindow)(target)); return; case 2: this.frame = ((System.Windows.Controls.Frame)(target)); return; } this._contentLoaded = true; }