Examples: NotesUIView class

  1. This example examines the current view as it is opened and queries the user if the view is a calendar view.
    (Globals) (Declarations)
    %INCLUDE "lsconst.lss"
    Sub Queryopen(Source As Notesuiview, Continue As Variant)
      Dim view As NotesView
      Set view = Source.View
      If view.IsCalendar Then
        If Messagebox ("Do you want to continue?", _
        "Calendar view") = IDNO Then
          Continue = False
        End If
      End If
    End Sub
  2. This view action prints the current view.
    Sub Click(Source As Button)
      Dim wks As New NotesUIWorkspace
      Dim view As NotesUIView
      Set view = wks.CurrentView
      Call view.Print()
    End Sub