View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
Chip Pearson Chip Pearson is offline
external usenet poster
 
Posts: 7,247
Default File Save As through VBA

Try


ThisWorkbook.SaveAs Filename:= _
"C:\" & Format(Now, "mmddhhmm") & ".xls"


--
Cordially,
Chip Pearson
Microsoft MVP - Excel
Pearson Software Consulting, LLC
www.cpearson.com



wrote in message
oups.com...
I have a command button in my excel file after clicking on which
it
does some calculations.

I need a small piece of code at the end of my code which will
save a
copy of that file (Save As) in C:\ with the current date and
time (eg.
xxx06271315.xls) 0627 is the date 27th June and 1315 is the
time 1:15
PM

Can anybody help?