View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.misc
Petester
 
Posts: n/a
Default File name equal cell contents

Is there a way to have two cells in the range, so the the two cells make up
the file name?

"Frank Kabel" wrote:

Hi
in a macro
sub save_it()
dim fname
with activeworkbook
fname = .worksheets("sheet1").range("A1").value & ".xls"
.saveas fname
end with
end sub


"-tinka" wrote:

Is it possible to make an Excel (2003) template (or a macro in the template)
to save a file with a specific cell-contents as file name? For example an
invoice-template where a cell contains the invoice number. I want it to
automatically save the file as "invoice-number".xls in default file location.

Thanks... :-)