Delete locked file on restart

Discussion forum for all Windows batch related topics.

Moderator: DosItHelp

Post Reply
Message
Author
Conk1
Posts: 12
Joined: 04 Dec 2009 09:43

Delete locked file on restart

#1 Post by Conk1 » 08 Feb 2010 09:49

I am trying to make a batch script that will delete certain locked files after a restart. So far I haven't been able to achieve this without using other programs.

Is there a command for getting rid of locked files on restart?

shiva
Posts: 18
Joined: 11 Jul 2011 03:53

Re: Delete locked file on restart

#2 Post by shiva » 02 Aug 2011 06:12

hi,
i dont know how to fild the locked files,
but i can suggest u a solution to this issue,
let the locked files are a.txt, c.txt

create a batch file nameed as autoexec.bat
and the content was
del e:\a.txt
del d:\b.txt

this file name has a special privilege it will get executed automatically on startup,
so u can write all the required actions that u intend to do,

thank you
shiva shankar

Post Reply