Subroutine to update a field in response documents after corresponding field in the parent document

This subroutine searches for all the response documents for the parent document and updates the corresponding related fields between them.
Sub UpdateResponseField (docParent As NotesDocument, parentFieldName As String, responseFieldName As String)
  Dim docCollection As NotesDocumentCollection
  Dim docResponse As NotesDocument  
  
  parentValue = docParent.GetItemValue(parentFieldName)
  Set docCollection = docParent.Responses
  If docCollection.Count <> 0 Then
     For i=1 to docCollection.Count
        Set docResponse = docCollection.GetNthDocument(i)
        If Not docResponse Is Nothing Then
           Call docResponse.ReplaceItemValue(responseFieldName, parentValue(0))
           Call docResponse.Save(True, False)
        End If
     Next
  End If    
End Sub

This was first published in March 2001

Dig deeper on Lotus Notes Domino Administration Tools

0 comments

Oldest 

Forgot Password?

No problem! Submit your e-mail address below. We'll send you an email containing your password.

Your password has been sent to:

-ADS BY GOOGLE

SearchWindowsServer

Search400

  • iSeries tutorials

    Search400.com's tutorials provide in-depth information on the iSeries. Our iSeries tutorials address areas you need to know about...

  • V6R1 upgrade planning checklist

    When upgrading to V6R1, make sure your software will be supported, your programs will function and the correct PTFs have been ...

  • Connecting multiple iSeries systems through DDM

    Working with databases over multiple iSeries systems can be simple when remotely connecting logical partitions with distributed ...

SearchEnterpriseLinux

SearchDataCenter

SearchExchange

SearchContentManagement

Close