protected override void OnStartup(StartupEventArgs e) { Process thisProc = Process.GetCurrentProcess(); var p = Process.GetProcessesByName(thisProc.ProcessName); if (p.Length > 1) { Environment.Exit(0); return; } KeyBoardWindow.ShowDefault(() => Environment.Exit(0)); }
private void Button_Click(object sender, RoutedEventArgs e) { KeyBoardWindow.ShowDefault(); }