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 gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

rename files.

Status
Not open for further replies.

gransbpa

Programmer
Jun 5, 2001
98
NL
I have several directories with files having as its last six positions of their names a time stamp (for example uploadCutpiece010603) . Now, every month these files have to be renamed to a different timestamp. The to be replaced part is always the last six positions of the filename, and the new part can always be derived from the current date. My question is: When the directories in which these files reside (number of directories can vary) are always under the same root directory, is it then possible to code my application (MS Access with VBA) to automatically rename all the files in them?

Thanks for all the help.
 
Hi

Yes, see the Dir() function in help, this will allow you to return filenames and / or directory names, using wild cards if you wish.

See also the rename command in help

Hope this helps Regards

Ken Reay
Freelance Solutions Developer
Boldon Information Systems Ltd
Website needs upgrading, but for now - UK
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top