Path: utzoo!attcan!uunet!ns-mx!iowasp.physics.uiowa.edu!maverick.ksu.ksu.edu!zaphod.mps.ohio-state.edu!swrinde!ucsd!ucbvax!bloom-beacon!eru!luth!sunic!tut!funic!uwasa.fi!ts From: ts@uwasa.fi (Timo Salmi LASK) Newsgroups: comp.sys.ibm.pc.programmer Subject: Re: DOS Batch Programming Keywords: DOS Batch DELETE Message-ID: <1990Jun25.215129.24826@uwasa.fi> Date: 25 Jun 90 21:51:29 GMT References: <1990Jun24.043414.24256@caen.engin.umich.edu> Organization: University of Vaasa Lines: 24 In article <1990Jun24.043414.24256@caen.engin.umich.edu> mrice@caen.engin.umich.edu (Michael Rice) writes: > >Hi. I would like to know if the following can be done? >I have a batch file that does a DEL subdirectory >where subdirectory is some temporary directory. The problem is >DOS asks the question about "All files will be deleted Are you >sure? " There are a couple of ways to do this, the most elegant being echo y | del YourSub\*.* > nul, as pointed out in this newsgroup by several postings. (There have also been a couple of clearly incorrect solutions suggested). If you want to delete the files AND the subdirectory, that can be done as well. For how, I shall refer you to /pc/ts/tsbat21.arc, which has quite a number of batch files with accumulated batch programming tricks in them. Available by anonymous ftp from chyde.uwasa.fi, Vaasa, Finland. If you need prerecoded information about chyde.uwasa.fi ftp, just send me an email request. ................................................................... Prof. Timo Salmi (Moderating at anon. ftp site 128.214.12.3) School of Business Studies, University of Vaasa, SF-65101, Finland Internet: ts@chyde.uwasa.fi Funet: gado::salmi Bitnet: salmi@finfun