private void btnMainSample_Click(object sender, RoutedEventArgs e) { var sampleWindow = new ShowcaseWindow(); sampleWindow.Owner = this; sampleWindow.WindowStartupLocation = WindowStartupLocation.CenterScreen; sampleWindow.ShowDialog(); }