This forum is closed to new posts and
responses. The content has been migrated to the Digital Solutions Community. Please join us there for new content as well as this content. For customer support, please visit the official HCL customer support channels below:
RE: Agent to add readers field ~Holly Desveluzen 10.Mar.07 03:19 PM a Web browser Applications Development 7.0.1All Platforms
If you are running this code in an agent that acts on selected documents in a view, you need a little more code.
Dim session As New NotesSession
Dim db As NotesDatabase
Dim coll As NotesDocumentCollection
Dim doc As NotesDocument
Dim readersItem As NotesItem
Dim newValues( 1 To 2 ) As String
Set db = session.CurrentDatabase
Set coll = db.UnprocessedDocument
Set doc = coll.GetFirstDocument
While Not (doc Is Nothing)
Set readersItem = New NotesItem(doc, "docReaders", newValues, READERS)
Call doc.Save( True, True )
Set doc = coll.GetNextDocument(doc)
Wend