Click here to Skip to main content
15,920,602 members
Articles / Desktop Programming / Win32

How to avoid multiple instances of your Windows application

Rate me:
Please Sign up or sign in to vote.
5.00/5 (2 votes)
3 Feb 2011CPOL 6K   1  
This solution works in Windows environment under Visual Studio.I don't know if there is a Linux equivalent.I use a counter common for all processes.#pragma data_seg("counter") // counter common for all processesLONG gs_nCtApp = -1; #pragma data_seg()#pragma comment(linker,...

Views

Daily Counts

License

This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)


Written By
Software Developer Aloatec
France France
This member has not yet provided a Biography. Assume it's interesting and varied, and probably something to do with programming.

Comments and Discussions