OnAfterSave Event
Occurs after the active document has been saved by the user.
Private Sub expression_OnAfterSave(Success As Boolean)
expression A variable name which references an object of type PageWindowEx declared using the WithEvents keyword in a class module.
Success A Boolean that indicates if the operation was successful. If True, the file was saved.
Example
The event in the following example occurs after the active document is saved in an extended page window. A message is displayed to the user based on the result of the operation.
Private Sub PageWindowEx_OnAfterSave(Success As Boolean)
'Displays message based on value of Success
If Success = True Then
MsgBox "The file " & PageWindowEx.ActiveDocument.Title & " was saved."
Else
MsgBox "The file " & PageWindowEx.ActiveDocument.Title & " was not saved."
End If
End Sub