I have a form with a embedded view and the first column on the view contains the UNID of the docs:
"[<INPUT TYPE=radio NAME=\"CheckBox\" VALUE=\"" + @Text(@DocumentUniqueID) + "\">]" Also in the form I have a button -
Press this - with
@Command([ToolsRunMacro]; "test") command.
The agent
test is:
Sub Initialize
Dim session As New notessession
Dim db As notesdatabase
Dim doc As notesdocument
Dim item As notesitem
Set db = session.currentdatabase
Set doc = session.documentcontext
Set item = doc.GetFirstItem( "CheckBox")
If item.text<>"" Then
Forall v In item.Values
Set doc = db.getdocumentbyunid(Cstr(v))
vHTML = vHTML + "</TD><TD>" + {</TD><TD><FONT COLOR="red"> ok </FONT><BR>}
Print vHTML
End Forall
End if
End Sub
I need to get the ID of the current doc from the view with a radio button. When I try to use it in this way the agent works fine but when I try to use the same code into a
$$ViewTemplate for view1 I can't get the UNID ! It seems that it doesn't see the
CheckBox field.
Eg. For the ($All) view from the Mail DB (I added the extra column with the UNID value). It has a form template
$$ViewTemplate for ($All) in which I added my button
Press this and I can't get the CheckBox value.
How can get this value in this situation (using a $$ViewTemplate form) ? 10x