Attach a script file to a file synchronized MID Server
You can attach a script file to synchronize to a connected MID Server.
Before you begin
About this task
You can attach multiple files, but the last attached file gets synchronized to the MID Server. If you delete the attachment, the script file becomes inactive, and the synchronized file is deleted from the MID Server.
Procedure
How script file synchronization works on the MID Server
Script files attached to a record stay synchronized with a connected MID Server.
Script files synchronized with the MID Server are stored on the instance in the MID Server
Script File [ecc_agent_script_file] table, which you can access in the module.
When the MID Server first connects to the instance, the instance creates a directory called \scripts in the MID Server root. The instance then creates a parent directory in the path \scripts\<parent name> using definitions from the ecc_agent_script_file table. Finally, the instance creates the script files themselves inside the parent directory using the records from the ecc_agent_script_file table.
The instance creates each script file in the parent directory on the MID Server using the record Name from the ecc_agent_script_file table as the file name and the Script field payload as the file contents. The synchronization of the script file continues to work as if the script was manually added to the form.
See Attach a script file to a file synchronized MID Server for instructions on how to attach a script file.