Re: Batch file executed at startup



Trevor,

Sometimes if a file is locked by some process all you need to do is reboot
or kill explorer.exe and restart it.

You can get to the Run command whether explorer.exe is running or not. If
you can get to the Run command, you can get a command prompt.

At *any* time that the Task Manager is open, you can click File | New Task
(Run...) | Type: cmd in the Run box | Click OK

New Task (Run...) is identical to the Run command on the Start menu.

--
Hope this helps. Let us know.

Wes
MS-MVP Windows Shell/User

In news:%23HwnLju8FHA.1292@xxxxxxxxxxxxxxxxxxxx,
Trevor L. <tandcl@xxxxxxxxxxxxxxx> hunted and pecked:
> Wesley Vogel wrote:
>> [[Deleting the current directory
>> You cannot use rmdir to delete the current directory. You must first
>> change to a different directory (not a subdirectory of the current
>> directory) and then use rmdir with a path. If you attempt to delete
>> the current directory, the following message appears:
>>
>> The process cannot access the file because it is being used by another
>> process.]]
>> Rmdir (rd)
>>
http://www.microsoft.com/resources/documentation/windows/xp/all/proddocs/en-us/rmdir.mspx
>>
>> Kill explorer.exe and use the command prompt to delete the folder.
>>
>> Open the Task Manager...
>> Ctrl + Shift + Escape | Click on the Processes tab | Locate and
>> highlight explorer.exe | Right click explorer.exe | Click End Process
>>> Click
>> Yes to the Task Manager Warning that pops up | File | New | CTRL key
>> + click New Task (Run...)
>>
>> Then type or paste into the command prompt:
>> rmdir C:\Documents and Settings\Trevor\My Documents\My Webs\oldzip /Q
>>
>> --
>> Hope this helps. Let us know.
>>
>> Wes
>> MS-MVP Windows Shell/User
>>
>> In news:ONNCpWo8FHA.472@xxxxxxxxxxxxxxxxxxxx,
>> Trevor L. <tandcl@xxxxxxxxxxxxxxx> hunted and pecked:
>>> This is a simple question.
>>>
>>> I have a folder which I can't delete as it is in use - I find
>>> explorer.exe has it. I can't close explorer as then I want have
>>> access to the folder to delete it
>>>
>>> I therefore want to execute a file at start-up to do the deletion
>>> The contents would be:
>>> rmdir C:\Documents and Settings\Trevor\My Documents\My Webs\oldzip /Q
>>>
>>> Where do I put this code?
>>> Is it autoexec.bat ?
>>> Or what?
>>> --
>>> Cheers,
>>> Trevor L.
>>> Website: http://tandcl.homemail.com.au
>
> Thanks, Wesley.
>
> I knew that I could kill explorer.exe, but then I didn't know how to get
> to the command prompt as all the icons etc, are removed. I think you are
> saying that I can get to it from the Task Manager.
>
> Luckily, I tried to delete the folder one more time and ths time it
> worked. (I have no idea why explorer was using it.) So I won't need to go
> through the steps you gave. It is good to know that commands can be
> executed after explorer is closed.
>
> --
>
> Thanks again,
> Trevor L.
> Website: http://tandcl.homemail.com.au

.



Relevant Pages

  • Re: downloaded files say in properties Blocked
    ... >> Explorer to download files, ... when you want to clean out all the streams in files in a folder ... command prompt completely) and in Explorer locate the folder you want ...
    (microsoft.public.windowsxp.security_admin)
  • Re: Windows Explorer crashes... help!
    ... Write down the path to the problem folder. ... Assuming there are no errors, leave the Command Prompt there, open ... Windows Explorer and try to open the Pictures folder. ... Check to see if the folder works now, using Windows Explorer. ...
    (microsoft.public.windowsxp.general)
  • Re: Cannot view files and folder in explorer
    ... Click in the blank right-hand pane. ... Q179875 Windows Explorer Does Not Display Item's Contents in Right ... >If I go to the command prompt, it puts me in my user folder and I am able to ...
    (microsoft.public.security)
  • capture list of files in a folder in Windows Explorer to email
    ... I'm trying to copy a long list of the files that are contained in a folder in Windows ... Explorer into an email message. ... How to Create a File List at a Command Prompt ...
    (microsoft.public.windowsxp.help_and_support)
  • HEEEELP! Cant delete a file
    ... command prompt window..then task manager...ending the ... >I have run every program that could kill it i have (and i ... have several...all fully updated) and even in safe mode it ... All my AV and windows software is fully updated. ...
    (microsoft.public.windowsxp.general)