check if EZPPClient Installer is already running

This commit is contained in:
HorizonCode 2021-05-27 20:02:13 +02:00
parent cd06d53130
commit e8717981a2
1 changed files with 3 additions and 0 deletions

View File

@ -36,6 +36,9 @@ namespace EZPPClient_Installer
public MainWindow()
{
var alreadyRunning = System.Diagnostics.Process.GetProcessesByName(System.IO.Path.GetFileNameWithoutExtension(System.Reflection.Assembly.GetEntryAssembly().Location)).Count() > 1;
if (alreadyRunning)
this.Close();
Instance = this;
InitializeComponent();
Init();