ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Renaming a file (https://www.excelbanter.com/excel-programming/288928-renaming-file.html)

Paul C[_2_]

Renaming a file
 
I need to use VBA to automaticaly rename an excell file, the file that needs to be renamed is not open at the time.

Ron de Bruin

Renaming a file
 
You can use this

OldName = "C:\Data\OLDFILE.xls"
NewName = "C:\Data\NEWFILE.xls"
Name OldName As NewName


--
Regards Ron de Bruin
(Win XP Pro SP-1 XL2000-2003)
www.rondebruin.nl



"Paul C" wrote in message ...
I need to use VBA to automaticaly rename an excell file, the file that needs to be renamed is not open at the time.





All times are GMT +1. The time now is 08:10 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com