Is there a way to stop two instances of the same program to be executed at the same time?
Heya moxy,
Check a few threads below.. :)
But basically it's something like this:
start:
invoke FindWindow,NULL,ADDR AppName ;search if Proggy already exist.
.IF eax!=0 ;if yes
mov dblinst,eax ;mov the handle of the proggy into dblinst
;get visible and on top
invoke BringWindowToTop,dblinst
invoke SetForegroundWindow,dblinst
invoke ExitProcess,0 ;get out again - result : No double instances
.ENDIF