ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Rename Files according to Excel (https://www.excelbanter.com/excel-programming/352584-rename-files-according-excel.html)

nima

Rename Files according to Excel
 

Hello. I am new to macros and such. I am trying to make an excel
spreadsheet that will convert files (with known names) into more
descriptively named derived from some cells in excel..I have no idea
where to start :(


--
nima
------------------------------------------------------------------------
nima's Profile: http://www.excelforum.com/member.php...o&userid=30408
View this thread: http://www.excelforum.com/showthread...hreadid=509181


NickHK

Rename Files according to Excel
 
nima,
assuming you have you all your data on a worksheet, something like:
Dim FileName As Range
For Each FileName In ThisWorkbook.Worksheets("Data").Range("FileNames")
Name FileName.Value As FileName.Offset(0, 1).Value
Next

You should error checking to ensure the the files exist, names valid, etc.

NickHK

"nima" wrote in message
...

Hello. I am new to macros and such. I am trying to make an excel
spreadsheet that will convert files (with known names) into more
descriptively named derived from some cells in excel..I have no idea
where to start :(


--
nima
------------------------------------------------------------------------
nima's Profile:

http://www.excelforum.com/member.php...o&userid=30408
View this thread: http://www.excelforum.com/showthread...hreadid=509181





All times are GMT +1. The time now is 01:21 PM.

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