I am going to boil this down to the basics, because what I have written below is all I have at the moment, and will be able to expand the complexity once I get this working. Please tell me what I am doing wrong.
I inherited a Web application with a main form, with a WebQueryOpen named "WebLoad", and it is written in formula language. It is a very long and complicated formula agent, and I want to have it, on the last line, initiate a LotusScript agent.
The LotusScript is temporarily named "aaa".
This agent is extremely simple:
Dim s as new NotesSession
Dim doc as NotesDocument
set doc = s.documentcontext
doc.aaaTest = "yes"
'this was my last line added to try to get this to work, and it still doesn't.
call doc.save(true,true)
The last line of the formula agent is : @Command( [ToolsRunMacro] ; "aaa" )
On my main form, I have a computed text field with the formula:
"testfield : " + aaaTest
I would expect, when I open an existing main doc, the computed text to show me:
testfield : yes
but it shows
testfield :
Also, since I am calling the doc.save, I looked at the document properties after I have opened it in a browser, and this field is not even an item on the document.
Either you are unable to call a LotusScript agent from a formula WQO agent, or I am doing something very basic incorrectly.
The LotusScript agent is set to run as a Web user, and has Run on Behalf of set to the Abbreviated name of the User ID with the Manager rights in the ACL.
I confirmed all of the lines in the formula agent run correctly up until this call to run the other agent.
I am hoping someone can see what I have wrong, either in the design or my understanding.
Thank you.