Lotus Software logo
IBM Lotus Domino Designer 8.5
  Versions 8.5 and 8.5.1






Examples: UnprocessedDocuments property

  1. This agent script allows a user to approve multiple requisitions at once by processing the currently selected documents in the Requisitions view. UnprocessedDocuments returns the documents that are currently selected in the view. The script iterates over each document and, if the Approver item contains the current user's name, it sets the Approved item to "Yes."
  2. Sub Initialize
    
    Dim session As New NotesSession
    Dim db As NotesDatabase
    Dim collection As NotesDocumentCollection
    Dim doc As NotesDocument
    Set db = session.CurrentDatabase
    Set collection = db.UnprocessedDocuments
    Set doc = collection.GetFirstDocument()
    While Not(doc Is Nothing)
    Set item = doc.GetFirstItem( "Approver" )
    If item.Contains( session.UserName ) Then
    doc.Approved = "Yes"
    Call doc.Save( False, True )
    End If
    Set doc = collection.GetNextDocument(doc)
    Wend
    End Sub
  3. This agent script runs on all newly created and modified documents, and its purpose is to modify the Status item of each document it processes.
  4. This agent script runs on all unread documents, and its purpose is to put unread documents into a folder.
Related topics
UnprocessedDocuments property




Library | Support | Terms of use |

Last updated: Monday, October 5, 2009