Hello
Looking to do this steps before close the workbook
1- save
2 - save as in desktop (overwrite if exsist)
3 - close without alert
so it will generate backup of the file in my desktop everytime I close the file
Hello
Looking to do this steps before close the workbook
1- save
2 - save as in desktop (overwrite if exsist)
3 - close without alert
so it will generate backup of the file in my desktop everytime I close the file
The ThisWorkbook event VBA procedure for starters :
PHP Code:
Private Sub Workbook_BeforeClose(Cancel As Boolean)
Save
SaveCopyAs Replace(FullName, Path, CreateObject("WScript.Shell").SpecialFolders("Desktop"))
End Sub
► Do you like it ? ► ► So thanks to click on bottom left star icon « ★ Add Reputation » ! ◄ ◄
sometimes there is alert that there file with same name in desktop, there any code to avoid the alret and always overwrite?
So weird as not on my side
Anyway you can set Application.DisplayAlerts to False before SaveCopyAs and set it to True after
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks