Send Remote Script Trigger (script step reference)

Activator Plug-in > Script steps reference > Send Remote Script Trigger
Activator Plug-in for FileMaker Pro

Send Remote Script Trigger

Send a message to the computer with this IP address. This message will trigger the specified script.

SyntaxScript step badge

Send Remote Script Trigger [ Select ; Result (error) ; IP Address ;
Port number ; Security ID ; File name ;
Script name ; Your ID ; User text ]

Options

Select entire contentsreplaces the entire contents of a field with the result. If not checked the result replaces the currently selected portion of the field
Result (error)an error code
IP Addressthe IP address of the computer that must be triggered
Port number(optional) use the specified portnumber, if you leave this empty the default portnumber of the Activator is used (TCP port 54242)
Security ID(optional) an ID that must be equal to the security ID of the receiving computer
File namethe name of the file that contains the script
Script namethe name of the script
Your IDa free to use ID that you can supply to identify the event
User texta free to use text that you can supply for your own needs

Returned Result

Data type returned

Error code

Result

If successful it returns 0.
If unsuccessful it returns an error code starting with $$ and the error code. Returned error codes can be:

$$-50parameter errorthere was an error with the parameters
$$-4228portnumber out of range: use 0 to 65535

Other errors may be returned. See our OSErrrs database for explanations.

Originated in

Activator Plug-in 4.5

Compatibility

FileMaker Pro 16

Considerations

You can omit the portnumber option. In this case the default portnumber 54242 is used.

The security ID makes listening for messages safer. No one can trigger a script on a remote computer, unless they know the security ID. If the sender sends a different security ID no triggering occurs. See “Start Message Listener” for more information on security ID.

The maximum length of a remote message is 6000 characters. To accomodate the name of the script etc, this means that you should not send User text that is longer than 5000 characters.

Example

Send Remote Script Trigger [ Select ; gErrorCode ; "192.168.1.1" ; "secretword" ; 
			"Filename.fmp12" ; "Triggerscript1" ; "1234567" ; "Hello there!" ]

Example 2

We assume that in your FileMaker file the following fields are defined:

gIPAddress		Global, text
gSecurityID         	Global, text
gYourID    		Global, text
gYourText  	  	Global, text
gErrorCode		Global, text

gIPAddress and gSecurityID should contain the IP address resp. the security ID of the computer you want to trigger. gYourID and gYourText can be filled with the message you want to send to the other computer. Add the following script step:

Send Remote Script Trigger [ Select ; gErrorCode ; Port number: 51000 ; gIPAddress ; gSecurityID ; 
			"Remote.fmp12" ; "Triggerscript1" ; gYourID ; gYourText ]

This will trigger script “Triggerscript1” in database “Remote.fmp12” on the remote computer.

Related script stepsScript step badge

Delete Script Trigger
Start Message Listener

Related functionFunction badge

Actr_SendRemoteEvent

Related topics

Activator Plug-in online help (overview)


Online Help Page for Activator Plug-in for 12 to 16 –> Send Remote Script Trigger (actrp7615) 2017-0831 20:29:36