Talk About Network



Register and Login
Nick
Password
Register create new account Sign up is FREE and you can post replies, new topics, bookmark posts and more!
Recover lost password


Programming > MSDOS Programmer > how to delete o...
Latest [ Topics | Posts ] Archive Post A New Topic Post a Reply
<< Topic < Post Post 1 of 1 Topic 406 of 494
Post > Topic >>

how to delete old folders?

by assafm@[EMAIL PROTECTED] Jul 22, 2006 at 10:45 AM

there is a section in the "backup.bat" file i need your help with

for /F "tokens=2-4 delims=/- " %%A in ('date/T') do set var=
%%B.%%A.%%C
md %var%
cd C:\%var%\

those lines create a folder with today date, with a specific format
and then i use xcopy to backup the files to this folder

after X days of backuping, i have X folders on the hd, for example:
20.07.2006
21.07.2006
22.07.2006
and so on....

i need to add a section that check the hd disk space
if it's less then 1 gb
then it should delete the oldest folder

i will appreciate any help, 
thanks very very much 
Assaf M.




 1 Posts in Topic:
how to delete old folders?
assafm@[EMAIL PROTECTED]   2006-07-22 10:45:34 

Post A Reply:
  Go here to Signup

AddThis Feed Button


About - Advertising - Contact - Frequently Asked Questions - Privacy Policy - Terms of Use - Signup

Contact
tan12V112 Sat May 17 13:30:59 CDT 2008.