navigation
a webmaster learning community
     Home    Register     Search      Help      Login    
Sponsors

Shopping Cart Software
Ecommerce software integrated into Frontpage, Dreamweaver and Golive templates. No monthly fees and available in ASP and PHP versions.

Website Templates
We also have a wide selection of Dreamweaver, Expression Web and Frontpage templates as well as webmaster tools and CSS layouts.

Frontpage website templates
Creative Website Templates for FrontPage, Dreamweaver, Flash, SwishMax

Search Forums
 

Advanced search
Recent Posts

 Todays Posts
 Most Active posts
 Posts since last visit
 My Recent Posts
 Mark posts read

 

Delete files using Batch.

 
View related threads: (in this forum | in all forums)

Logged in as: Guest
Users viewing this topic: none
Printable Version 

All Forums >> Web Development >> Server Issues >> Delete files using Batch.
Page: [1]
 
earthangelghost

 

Posts: 1
Joined: 8/18/2008
Status: offline

 
Delete files using Batch. - 8/18/2008 9:40:38   
First a little background. I have never touched batch files in my entire life. I have done a bit of HTML and C++ but I have forgotten most as I've not touched it much in the past 8 years.
I'm working for a company and my boss has said if I can make a batch file to delete all but the last 7days of files within a directory then I he buys dinner on Monday.

Problem is I have looked at batch files and realised without a bit of help I have no idea where to start. I normally look at code logically and then trial and error, this isn't going to happen with what i've seen within this week.

So can someone give me some pointers on how to get a simple batch file like this working. From what I can figure I need it to find the folder, check the date and compair to system date, then delete anything over 7 days. Now I just need a help to get the code for this.

Help appreciated in advance.
treetopsranch

 

Posts: 1141
From: Cottage Grove, OR, USA
Status: offline

 
RE: Delete files using Batch. - 8/18/2008 12:52:48   
Look here: http://forums.devshed.com/windows-help-34/deleting-files-older-than-14-days-using-batch-file-script-364137.html

and:

http://www.experts-exchange.com/OS/Microsoft_Operating_Systems/Windows/Q_22162047.html
(Bottom of page)

Google it. You will find some other ways to do it. Some with .bat files some with other scripting languages.

_____________________________

Don from TreeTops Ranch, Oregon

"I've got a taste for quality and luxury"


(in reply to earthangelghost)
Page:   [1]

All Forums >> Web Development >> Server Issues >> Delete files using Batch.
Page: [1]
Jump to: 1





New Messages No New Messages
Hot Topic w/ New Messages Hot Topic w/o New Messages
Locked w/ New Messages Locked w/o New Messages
 Post New Thread
 Reply to Message
 Post New Poll
 Submit Vote
 Delete My Own Post
 Delete My Own Thread
 Rate Posts