RunOnServer (NotesAgent - LotusScript®)

Runs the agent on the computer containing the database.

Note: This method is new with Release 4.6.1.

Defined in

NotesAgent

Syntax

status = notesAgent.RunOnServer( [ noteID$ ] )

Parameter

noteID$

String. Optional. The note ID of a document. This value is passed to the ParameterDocID property of the called agent.

Note: This parameter is new with Release 5.0.2.

Return value

status

Integer. Status of the operation where 0 indicates success.

Usage

This method runs any agent regardless of source language (simple action, formula, LotusScript®, Java).

You cannot run an agent recursively (cannot call it from itself).

The rules governing the access level required to run an agent using the RunOnServer method are the same as for any other server-based agent. For information regarding agent security, see Setting up agent security.

The user cannot interact directly with a called agent. User output goes to the Domino® log.

You cannot debug a called agent.

On a local database, the RunOnServer method works like the Run method, that is, runs the agent on the local computer.

Note: This behavior is new with Release 5.0.2. The former behavior was to issue the error message "RunOnServer must be used with a remote database."

If a Notes® client invokes RunOnServer, security is through the signer of the agent.

For COM applications, the Notes® program directory must be in the application path.

Example