Does anyone know if I can initiate an agent from the AS400 in either Java, Cobol, CL, or RPG?
thx
Does anyone know if I can initiate an agent from the AS400 in either Java, Cobol, CL, or RPG?
thx
Subject: RE: I want to call an agent from the AS400
I’m not sure we’re talking about the same thing. We have an iseries application (green screen 5250 app). when data is entered into a particular field I want to initiate a domino agent and I have a variety of programming lanugages I can use to call the agent. Question is are there any API’s on the iseries I can use to call a domino agent?
thanks again.
Subject: RE: I want to call an agent from the AS400
You can call a Java program that resides on the iSeries via RPG or a CL (probably when a record is created, modified, etc). The Java program can then establish a Session to the Notes server, open the Notes database, get a handle to the agent, and run it. You may also consider just having the Java program do the work that the agent would do.dgg
Subject: RE: I want to call an agent from the AS400
I don’t know if this will help but…
Is it possible to call the agent via the ‘run remote command’ command (runrmtcmd) from cl or rpg?
Something like:
RUNRMTCMD Server(servername) cmd(call pgm(qnotes/agentname) Parm(‘parm1’ ‘parm2’ etc…))
Subject: RE: I want to call an agent from the AS400
Thank you both, I’m still trying. The RunRmtCmd doesn’t have server as a parameter, but I did try…RUNRMTCMD
CMD(‘call pgm(qnotes/CreateLetterOnlineAgent)’ RMTLOCNAME(DOMINO1.TRS)
Remote location TRS for conversation B not found.
Subject: RE: I want to call an agent from the AS400
I’m sorry…
Try using rundomcmd (replacing runrmtcmd) as shown in my prior message.
Sorry, I gave you the wrong command.
Subject: RE: I want to call an agent from the AS400
Thanks for following-up. Built in CL command has SBMDOMCMD, but I did find RUNDOMCMD utility at this link.
http://www.ibm.com/servers/eserver/iseries/domino/devtools/rundomcmd/rundomcmd.htm
Subject: RE: I want to call an agent from the AS400
Good - please let me know if you get it working. This is something I may need to do in the near future.
Subject: RE: I want to call an agent from the AS400
Some not so encouraging news from this site.http://www.epromag.com/epnewsletters//index.cfm?fuseaction=ShowNewsletterIssue&ID=624
I’m running a release 5 server also, but I will try the SBMDOMCMD to submit a console command to run an agent. I will keep you posted.
Subject: RE: I want to call an agent from the AS400
Here is what I got working in release 6; In an AS400 CL program I issue the SBMDOMCMD Tell Amgr Run “DatabaseName.nsf” ‘AgentName’ . Beware, the agent you call cannot require a parameter as I was told. “You can’t supply a NoteID parameter via the console, so you need to re-code your agent to account for the possibility.”
Now…to automate the display of the newly created document…
Subject: RE: I want to call an agent from the AS400
We neded up sending an OpenAgent command to the browser.
http://…/crtletter.nsf/(CreateLetterOnlineWebAgent)?OpenAgent&Khayat&Malinda&
Subject: RE: I want to call an agent from the AS400
Great. Glad to see you are making progress! Keep us posted.
Subject: I want to call an agent from the AS400
See the run() and runOnServer() methods of Agent class in the Java API. And here is the product documentation.dgg