Mutex

C# Mutex for running single instance of a program

Here is some sample code that can be used in a c# application to make sure that only one instance of the program can run at a time. In order to do this you will use a Mutex (Mutual Exclusion) which is a type of system wide lock.