View Full Version : Batch File Problem
mryear2000
01-26-2001, 03:52 PM
How can I repress the confirmation to delete files in DOS when I use the all files [*.*] wildcards with the DEL command??
Thanks in advance
I use deltree /y, here's an example of one I use in a batch file....
deltree /y %ROOTDIR%\myprog~1\dap\ads\*.*
mryear2000
01-26-2001, 09:10 PM
I thought about using that but......
how can I use a command which windows 98
DOS Prompt does not seem to reconise??
Any help on this would be very...helpful :-)
It should do, I run Win98fe with the updates and its their.
Do a search for "Deltree.exe" it should be in "C:\Windows\Command"
Or
open a dos prompt and type "deltree /?" it should bring up what I got below.
C:\WINDOWS>deltree /?
Deletes a directory and all the subdirectories and files in it.
To delete one or more files and directories:
DELTREE [/Y] [drive:]path [[drive:]path[...]]
/Y Suppresses prompting to confirm you want to delete
the subdirectory.
[drive:]path Specifies the name of the directory you want to delete.
Note: Use DELTREE cautiously. Every file and subdirectory within the
specified directory will be deleted.
C:\WINDOWS>
On a final note are you sure your seting up the batch file to look for it?, as an example with the example I gave you yesturday the batch files starts like this. Make a batch file with the 4 lines below changing the directory and test it ( remember the directory below is only applicable to my machine.) When you click on the batch file assuming all is correct the dos box should appear and then disapear and if you have the target dir open you will have to refresh it to display the deletion, so to speak.
@echo off
cd %WINDIR%\command
deltree /y %ROOTDIR%\myprog~1\dap\ads\*.*
cls
<P ID="edit"><FONT class="small">Edited by Will on 01/27/01 02:00.</FONT></P>
mryear2000
01-29-2001, 09:05 AM
Cheers mate, its all sorted now.
I would also like to take the opportunity to say that the members of this site are just
THE BEST!
doesnt that leave you feeling forfilled and warm inside? :-)
Powered by vBulletin™ Version 4.1.0 Copyright © 2012 vBulletin Solutions, Inc. All rights reserved.