View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
NickHK NickHK is offline
external usenet poster
 
Posts: 4,391
Default Name and save files with current date & time

Combine .Save/.SaveAs with the constructed filename. Something like:

?format(now(),"yyyymmddhhmmss")
20070625154701
?format(now(),"yyyy-mm-dd hhmmss")
2007-06-25 155327
Also see the help for "User-Defined Date/Time Formats (Format Function)"

Of course, if you are saving more frequently than 1 time/second, you will
have to add finer time resolution or some kind of additional variance.

NickHK

"Jac" wrote in message
...
Hi,

I've automated my filtering task by using macro; and this macro would help
me to create new files to place the results of the filtering task. But I
would also wish that the macro could save those created files by using the
current date & time!

Could this be done???
Anyone out there has any ideal of how to get this thing done????
Please advice........

Thanking in advance.