Home |
Search |
Today's Posts |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
When using the GetSaveAsFilename method, the method returns FALSE if the user
clicks Cancel. Thus, you only need to check the result of the method. Dim response response = Application.GetSaveAsFilename if not response then ' User clicked false Workbooks(NumberOrNameHere).close else ' Do stuff End if HTH, Matthew Pfluger "JAO" wrote: I have written a macro that shows the Save As dialogue box, but I'd like to add code that closes a workbook if the user selects "cancel". Can anyone help? |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
cancel save | Excel Discussion (Misc queries) | |||
can I cancel a save | Excel Discussion (Misc queries) | |||
Hii All!!!! does anybody knows how can i cancel the save and the save as commands | Excel Programming | |||
Cancel Macro is user selects 'cancel' at save menu | Excel Programming | |||
How to Cancel a Save? | Excel Programming |