home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
CICA 1995 May
/
cica_0595_4.zip
/
cica_0595_4
/
UTIL
/
LOCKAP22
/
AD0001.BAT
next >
Wrap
DOS Batch File
|
1994-12-01
|
817b
|
37 lines
@echo off
rem
rem AD0001.BAT Steve Clarke May 1994
rem
rem Demo file showing how an administrator can remove all locks for
rem a specified machine. He should be sure that nobody is running
rem any programs on the machine first.
rem
set CONTROL=L:\LOCK\CONTROL
if q%1==q goto NoCmdLine
if exist %CONTROL%\*.%1 goto Files
if exist %CONTROL%\*._%1 goto Files
echo There are no lock files for machine %1
goto Fin
:Files
rem
rem Some networks (eg PCNFS) will not allow a user to change file permissions
rem on another user's files. This may not be the case with your network.
rem
attrib -r %CONTROL%\*.%1 > NUL
attrib -r %CONTROL%\*._%1 > NUL
del %CONTROL%\*.%1 > NUL
del %CONTROL%\*._%1 > NUL
goto Fin
:NoCmdLine
echo Usage: AD0001 [Machine_name]
:Fin
set CONTROL=
echo Done