Examples: DialogBoxCanceled Property

This script tests for the DialogBoxCanceled property, then prompts users to confirm that they want to cancel the dialog. You must attach this script to the QueryClose event for the form you specified with the DialogBox method of the NotesUIWorkspace class.

(Globals)(Declarations)
%INCLUDE "lsconst.lss"
Sub Queryclose(Source As NotesUIDocument, Continue As Variant)
  If Source.DialogBoxCanceled Then
    If Messagebox ("Do you really want to Cancel", _
    MB_YESNO+MB_ICONQUESTION, "Cancel") = IDNO Then
      Continue = False
    End If
  End If   
End Sub