Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Program to clean files in Windows 1

Status
Not open for further replies.

PeteAmsterdam

Programmer
Jun 3, 2005
76
US
Hello I need to create a Script/or batch pgm to delete all files prior to 10 days from a given directory in windows.

I was thinking perhaps of doing this on the Iseries via the IFS.

Perhaps some one has some codes already that does this or similar?

Thank you,
Peter
 
Is your Windows directory mapped over in the IFS ? In other words can you 'see' the Windows files from the AS400 in using e.g. WRKLNK ?
 
I am not sure if this would cover everything. Assuming it is, how would you do the script on ISeries?
 
I'd use IFS UNIX-like APIs unlink() and rmdir() to remove streamfiles and directories and lstat() to get the last accessed or change date.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top