User Name Password Register
DaniWeb IT Discussion Community
All
What is DaniWeb IT Discussion Community?
You're currently browsing the Windows NT / 2000 / XP / 2003 section within the Tech Talk category of DaniWeb, a massive community of 402,411 software developers, web developers, Internet marketers, and tech gurus who are all enthusiastic about making contacts, networking, and learning from each other. In fact, there are 3,051 IT professionals currently interacting right now! Registration is free, only takes a minute and lets you enjoy all of the interactive features of the site.
Please support our Windows NT / 2000 / XP / 2003 advertiser: Programming Forums
Views: 5638 | Replies: 2 | Solved
Reply
Join Date: Mar 2004
Posts: 54
Reputation: Khiladi420 is an unknown quantity at this point 
Rep Power: 5
Solved Threads: 0
Khiladi420 Khiladi420 is offline Offline
Junior Poster in Training

Creating Batch Files in WIndows XP

  #1  
Nov 10th, 2005
Im trying to create a batch file to remove a directory in Windows XP, obviously it asks whether you want to delete the directory yes or no, but i want it to delete automatically without it prompting me everytime for the yes/no, i have tried many switches like DEL /y & DEL | Y & a few more but none work for XP , is there anyway to get round this?
AddThis Social Bookmark Button
Reply With Quote  
Join Date: Jul 2005
Location: India
Posts: 642
Reputation: swatkat is an unknown quantity at this point 
Rep Power: 5
Solved Threads: 50
swatkat's Avatar
swatkat swatkat is offline Offline
Small Town Boy

Re: Creating Batch Files in WIndows XP

  #2  
Nov 10th, 2005
Hi,
You can use the rd command. Syntax is as follows:-
rd /s /q foldername

/s => Delete all files and subfolders in addition to the folder itself.
/q => Quiet - do not display Y/N confirmation. Assumes "Yes" as answer.

More info:-
http://www.ss64.com/nt/rd.html


By the way, in Windows 98/ME, you can use deltree command. Syntax is as follows:-
deltree/y foldername
/y => Do not display Y/N confirmation. Assumes "Yes" as answer.
"Only two things are infinite, the universe and human stupidity, and I'm not sure about the former."
-Albert Einstein.
Reply With Quote  
Join Date: Mar 2004
Posts: 54
Reputation: Khiladi420 is an unknown quantity at this point 
Rep Power: 5
Solved Threads: 0
Khiladi420 Khiladi420 is offline Offline
Junior Poster in Training

Re: Creating Batch Files in WIndows XP

  #3  
Nov 11th, 2005
Thanks for the tip, works perect!
Reply With Quote  
Reply

Only community members can participate in forum threads. You must register or log in to contribute.

DaniWeb Windows NT / 2000 / XP / 2003 Marketplace
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)

 

Thread Tools Display Modes

Similar Threads
Other Threads in the Windows NT / 2000 / XP / 2003 Forum

All times are GMT -4. The time now is 2:06 pm.
Forum system based on vBulletin Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
©2003 - 2008 DaniWeb® LLC