View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
Bob Phillips[_7_] Bob Phillips[_7_] is offline
external usenet poster
 
Posts: 1,120
Default Macro Filename as Date

savename = Format(ActiveCell.Value,"yyyymmdd") & ".xls "


--
HTH

Bob Phillips

"Donkin" wrote in
message ...

I have the following Macro, which saves the file to the entry in Cell
AG13.

The Cell AG13 is formatted as a date and I would like to use the macro
but cannot format the filename as a date, when I try it saves as
“False.xls”

Range("ag13").Select

savename = ActiveCell.Value & ".xls "

ActiveWorkbook.SaveAs Filename:= _
"C:\" & savename, _
FileFormat:=xlNormal, Password:="", WriteResPassword:="", _
ReadOnlyRecommended:=False, CreateBackup:=False



Any help would be appreciated.


--
Donkin
------------------------------------------------------------------------
Donkin's Profile:

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