ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   naming a file based on cell value? (https://www.excelbanter.com/excel-programming/369082-naming-file-based-cell-value.html)

nokia3650

naming a file based on cell value?
 
i have a monthly report that gives me portfolio for each customer.name of
the sheets are generic (somethingxx where xx is number).i allready made
macro that take sheet after sheet and saves it as separate excel file but
then i must look into each file and rename it.can some value from the sheet
be used for a name of a file?

how can this be done?


thx


rene


Bob Phillips

naming a file based on cell value?
 
You could use something like

With ActiveSheet
.Name = .Range("A1").Value
End With

and change Activesheet to however you are addressing the sheet

--
HTH

Bob Phillips

(replace somewhere in email address with gmail if mailing direct)

"nokia3650" wrote in message
...
i have a monthly report that gives me portfolio for each customer.name of
the sheets are generic (somethingxx where xx is number).i allready made
macro that take sheet after sheet and saves it as separate excel file but
then i must look into each file and rename it.can some value from the sheet
be used for a name of a file?

how can this be done?


thx


rene



nokia3650

naming a file based on cell value?
 
thanks

that was so simple i am ashamend that i dint it figured out.

once again

htanks


rene
"Bob Phillips" wrote in message
...
You could use something like

With ActiveSheet
.Name = .Range("A1").Value
End With

and change Activesheet to however you are addressing the sheet

--
HTH

Bob Phillips

(replace somewhere in email address with gmail if mailing direct)

"nokia3650" wrote in message
...
i have a monthly report that gives me portfolio for each customer.name of
the sheets are generic (somethingxx where xx is number).i allready made
macro that take sheet after sheet and saves it as separate excel file but
then i must look into each file and rename it.can some value from the

sheet
be used for a name of a file?

how can this be done?


thx


rene






All times are GMT +1. The time now is 03:59 AM.

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