Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
kenny
 
Posts: n/a
Default How can you save a spreadsheet with a date stamp.

I need to save a file 2 times the first time for production, the second time
as a backup, I want the backup file to have a date stamp (ex.
gltransfer051506.csv).
i need the date to update each day it run.???
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
CLR
 
Posts: n/a
Default How can you save a spreadsheet with a date stamp.

This macro may do what you wish, it also adds the TIME......

Sub AddDateToFilename()
Dim Dname As String
Dname = ThisWorkbook.FullName
Dname = Left(Dname, Len(Dname) - 4) & _
Format(Now, "yyyymmdd_hh_mm_ss") & ".xls"
ThisWorkbook.SaveCopyAs Dname
End Sub

Vaya con Dios,
Chuck, CABGx3



"kenny" wrote:

I need to save a file 2 times the first time for production, the second time
as a backup, I want the backup file to have a date stamp (ex.
gltransfer051506.csv).
i need the date to update each day it run.???

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
save a spreadsheet file with same name but different version ASDonnelly New Users to Excel 1 April 13th 06 09:27 AM
Need to insert file modified date of Excel spreadsheet in a cell dj in Mass. Excel Discussion (Misc queries) 0 March 23rd 06 09:41 PM
Insert Automatic, Non-Updating Date Stamp Ken Zenachon Excel Discussion (Misc queries) 8 January 18th 06 06:52 PM
My hyperlink in an excel spreadsheet will not save. sheilag Excel Discussion (Misc queries) 3 September 14th 05 03:57 PM
How to save an excel spreadsheet as a text file without added quot Dozzle Excel Discussion (Misc queries) 2 April 11th 05 04:21 PM


All times are GMT +1. The time now is 02:30 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"