Thread: XL Save As
View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
Mike H Mike H is offline
external usenet poster
 
Posts: 11,501
Default XL Save As

Try this

Sub AATest()
mypath = "J:\Mydir\" 'Change to full path name
ThisWorkbook.SaveAs mypath & "Chart_" & Format(Date, "yyyy_mm_dd")
End Sub

Mike

"Risky Dave" wrote:

Hi,

I've got a macro that runs a whole set of stuff and I would like to add a
final tweak so that the file saves itself with a unique date stamp. This is
run off a button click within a file.

The format will be:

SaveAs \\network_path\yymmdd My charts.xls

Can anyone please tell me the syntax to make XL save as a different file
name, please?

(As you can see, I'm not a programmer - learning this stuff as I go along)

TIA

Dave