Lotus Script Agents - Passing Arguments

When using the WebQuerySave option how do you pass arguments to the Lotus Script Agent?
up2longAsked:
Who is Participating?
 
ghassan99Connect With a Mentor Commented:
There was a question about this like 3 months ago which I answered.  Anyway, passing arguments or parameters to agents is done in the http request to open the agent.  U specify it like a cgi variable in the URL with the '&' for example:
"http://www.abc.com/cast?openagent&login=1&user=john"
so the parameters in here are login=1 and user=john.  To check them now in the agent, u have to use the document context preperty of the notessession class.  And get the CGI variable Query_string.  This variable will hold everything after the '?' in the URL.  So it will contain "?openagent&login=1&user=john".  u then have to parse this to get your values with string manipulation functions like left, right, mid, instr and so on.
Simple code:
dim s as notessession
dim doc as notesdocument
set doc = s.documentcontext
messagebox doc.query_string(0)
0
 
HemanthaKumarCommented:
What arguments do u wan't to pass..?

~Hemanth
0
 
up2longAuthor Commented:
Any arguments.  I have variables that I've created and want to use them in an agent.  Unfortunately, I can't find any documentation on how to pass them.
0
Receive 1:1 tech help

Solve your biggest tech problems alongside global tech experts with 1:1 help.

 
ghassan99Commented:
sorry the first line of code should be:
dim s as new notessession

And I made a search on that question, I think it was deleted coz at that time the asker (I recall it was Anthony) refused the answer.  But it was a good discussion.
0
 
up2longAuthor Commented:
This is something that I've already done.  Unfortunately, it is not as clean as I wanted it to be.  It would be soooo much nicer if could pass args directly.  

In my case I've done as outlined above and I created a variable that points to a document in the database.  I then go to that document to find the user ID and correct password.  I feel like this is such a hassle and would have ultimately been better if I could have just passed the variables.

Thanks.
0
 
ghassan99Commented:
this is web standard so far, or u probably would have to go into JAVA.
0
All Courses

From novice to tech pro — start learning today.