Link to home
Start Free TrialLog in
Avatar of iamari
iamari

asked on

Update Response documents

I thought that by checking the Formulas inherit values in a response form's properties, the fields will be updated when I make a change in the main document.
But they don't!
How can I force a field in a response doc to copy the value from the field in the main doc every time?

Thanks for your help

Ion
ASKER CERTIFIED SOLUTION
Avatar of Paebdb
Paebdb

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of iamari
iamari

ASKER

Thanks, Paebdb

I've tried it after replacing
Set tempName = doc.GetFirstItem("Name")
with my field name, like
Set tempName = doc.GetFirstItem("Subject")

But it's not working and it doesn't give any error message either.

Anything else I should do?

Ion
Avatar of iamari

ASKER

I've got it. It worked after I've changed to
    While Not (runDoc Is Nothing)
          Call runDoc.ReplaceItemValue("Subject",newname)          
          Call runDoc.ReplaceItemValue("TempSubject",newname)      

Thanks a lot!

Ion
Did you also substitude the field names "Parent" and "TempParent" with the field names from your child document ?

Call runDoc.ReplaceItemValue("xxxxx",newname)          

Originally my code was not intended to be pasted and run, just to give the idea how it would be done.
Do you have a field "TempSubject" in your child document ? Otherwise you don't need this line.
And you also don't need

 Dim session As New NotesSession    
 Dim db As NotesDatabase      

and

 Set db = session.CurrentDatabase

I just forgot to delete it, sorry.