Hi all,
I 'm creating a form called processor on the $$view template and displaying a view using $$viewbody field.
I’ve created a button called OK on the processor form.
On click of OK button, form gets submitted and
an agent is run which will fetch the data of selected document in view to the fields in Processor form.
am using below code in the agent :
Sub Initialize
Dim session As New NotesSession
On Error 4091 Resume Next ' invalid universal ID
Dim context As NotesDocument
Dim process As NotesDocument
Dim item As NotesItem
Set context = session.DocumentContext
Set item = context.GetFirstItem("processdocs")
ForAll v In item.values
Set process = db.GetDocumentByUNID( v )
Call context.Replaceitemvalue("BoBetAfd1" , process.BranchNumberRO(0))
Call context.Replaceitemvalue("VBedrijfOnd", process.VBedrijfOnd(0))
Call context.Replaceitemvalue("VAfdeling", process.VAfdeling(0))
Call context.Replaceitemvalue("VNaam", process.BranchNameStructure(0))
Call context.Replaceitemvalue("VBedrijfOnd_1", process.VBedrijfOnd_1(0))
Call context.Replaceitemvalue("VAfdeling_1", process.VAfdeling_1(0))
End ForAll
Call view.Refresh
End Sub
However am not able to save this data in fields . Can anyone please help me out with this.
Thanks in advance.