ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Force save with timestamp (https://www.excelbanter.com/excel-programming/392761-force-save-timestamp.html)

Ryan

Force save with timestamp
 
I need a way to force excel to save the workbook after the user closes the
workbook. When it saves, I need it to save a timestamp to the original file
name.

Tom Ogilvy

Force save with timestamp
 
Use the beforeclose event.

http://www.cpearson.com/excel/events.htm



--
Regards,
Tom Ogilvy


"Ryan" wrote:

I need a way to force excel to save the workbook after the user closes the
workbook. When it saves, I need it to save a timestamp to the original file
name.


Vasant Nanavati

Force save with timestamp
 
In the ThisWorkbook module:

Private Sub Workbook_BeforeClose()
Me.Save
End Sub

The file will bear the new timestamp.
__________________________________________________ __________________________

"Ryan" wrote in message
...
I need a way to force excel to save the workbook after the user closes the
workbook. When it saves, I need it to save a timestamp to the original
file
name.





All times are GMT +1. The time now is 04:32 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com