All pastes #425160 Raw Edit

Gozzy

public text v1 · immutable
·published 2007-04-05 09:09 UTC
rendered paste body
 static void Main(string[] args)
        {
            Process ThisProcess = Process.GetCurrentProcess();

            Process[] AllProcesses = Process.GetProcessesByName(ThisProcess.ProcessName);

            if (AllProcesses.Length > 1)
            {
                /*
                MessageBox.Show(ThisProcess.ProcessName + " is already running",
        ThisProcess.ProcessName, MessageBoxButtons.OK, MessageBoxIcon.Error);
            
                 */
                Form1.voegToe("blabla");
            }
            else
            {
                Application.EnableVisualStyles();
                Application.SetCompatibleTextRenderingDefault(false);
                Application.Run(new Form1(args));
            }
            
        }
    }