(view source code of lockprog.bat as plain text)
:: Check if program is locked, and by whom
:: Unlock if it was you yorself who locked it
:: Check again if program is locked, and by whom
:: Lock it if it isn't locked by someone else
:: Start the program
:: (the first command line parameter, %1,
:: was used for this locking batch file)
MYPROGRAM.EXE %2 %3 %4 %5 %6 %7 %8 %9
:: Free the program
:: And quit
ECHO %LOCKEDBY% uses MYPROGRAM right now.
ECHO %LOCKEDBY% can free MYPROGRAM again by closing it normally.
ECHO Contact your helpdesk or administrator.
|page last uploaded: 2016-12-15, 11:20|