I have a routine that I run in the On Open event in Excel. It creates a backup of the file with the came name, directory, etc. but as a Date and Time to the file name. This is a very handy way "for me" to recovery from my self imposed disasters, I am supposed to put the code in the text area. I am not sure where that is. Not finding that I will carefully submit my current Subroutine, The issue that I am having is with With.ThisWorkBook and Application.WorksheetFunction. What are the corresponding values for Access. I have found where to put the code, I now just need to know what code to put there.
Please explain what I need to do to get to the Text Area or whatever,
here is the code:
==========================
Private Sub Workbook_Open()
Dim sFileName As String
Dim sDateTime As String
With ThisWorkbook
sDateTime = " (" & Format(Now, "yyyy-mm-dd hhmm") & ").xlsm"
sFileName = Application.WorksheetFunction.Substitute _
(.FullName, ".xlsm", sDateTime)
.SaveCopyAs sFileName
End With
End Sub
==========================
Thank you for any help you might provide and also "tell me where to go" on the Text Area feature.
DannyDont