I have a basic @formula agent I created to send a email notification out including a [doclink] back the database form. No problems there.
Now, if I execute said agent using @formula (@command[toolsrunmacro]) it runs fine and the agent pulls in the values from the fields I specify as it should. But if I run the same agent using LotusScript (agent.run) the agent still runs without errors but none of the field values get pulled in, including the [doclink]? What am I doing wrong?
LS code (NOTE the document has already been saved at least once prior to running this):
Sub Querysave(Source As Notesuidocument, Continue As Variant)
Dim agent As NotesAgent
Set agent = db.GetAgent(“AgentName”)
agent.Run
End Sub