How to pass the Document context in Xpages while calling an Agent?
How to pass the Document context in Xpages while calling an Agent? In Xpage, I am in need of calling a java agent with documentcontext from my Xpage, And also I am in need of passing my current document as a parameter... In Lotuscript we can do it as easily without saving the current document, but in Xpage I am using the following code., document1 is a current document. var agent=database.getAgent("AgentName"); agent.runWithDocumentContext(currentDocument.getDocument()); This code I am not able to get the values of my current document's items, but if I will use the following code, var agent