rename file

R

rob d

Hi
I'm a c++ programmer and have never used VBA.
Is it possible to use the stored filename in a word file to 'batch rename' a
whole load of word files that have lost their correct filename and directory
position?

cheers
Rob
 
J

Jonathan West

Hi Rob,

The VBA command to rename a file is the Name command, is has the format

Name x As y

where x and y are both strings, and repesent the filename or full pathname
of the file.

The command can be used to move files beteen folders provided that the
source and destination folders are both on the same logical drive.

--
Regards
Jonathan West - Word MVP
MultiLinker - Automated generation of hyperlinks in Word
Conversion to PDF & HTML
http://www.multilinker.com
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top