You can configure EFT to run executables, batch files, and scripts automatically when specific events occur. EFT calls these Commands. When the Event Rule is triggered, EFT executes the specified custom command and attributes.
To execute a Command from EFT’s Event Rule system
Identify the Command you want to execute with the Event Rule or create a new custom Command using the procedure in Creating a Command. Or you can create a new Command later from within the Event Rule (in step 6 below).
Open the Event Rule with which you want to execute the Command or create a new Event Rule using the procedure in Defining Event Rules.
(Optional) If you need to apply any conditional behavior, click it in the Conditions list.
In the Actions list, double-click Execute command in folder. The Action is added to the Event in the Rule Builder.
Links in the Rule Builder indicate parameters that must be defined to save the Rule.
In the Rule Builder, click one of the underlined text links. The Execute Command dialog box appears.
In the Choose an existing or create a new Command list, click the list to select the command. (If you did not create the Command in step 1, click New to create the Command now.)
The Executable path and Executable switches and/or parameters boxes display the path and switches for the selected Command. (If you want to change anything, you will have to close this dialog box, apply any changes to the Event Rule, go edit the Command, then reopen the Event Rule to continue defining it.)
In the Working directory box, type the path or click the folder icon to specify the folder in which the script or executable resides e.g., C:\EFTscripts. For mapped drives, use their UNC path. (File browse operations are disabled when you are connected remotely. You can't click the folder icon and browse, but you can type a path that is relevant to the EFT computer, not the remote interface).
(Optional) In the Command parameters box, include any parameters for the command.
You can select items in the Context variables list to add them as parameters. For example, suppose you want to run a script on a file that was uploaded and triggered the Event Rule. You would type the script name and the tag %FS.FILE_NAME%, as shown below:
dosomethingwithfile.vbs -file %FS.FILE_NAME%
Refer to Variables for details of available variables and how to use them.
EFT passes the complete variable along to the Command; however, due to limitations of some command-line applications, they may not be able to interpret the Command properly. In certain instances, such as when there is a semicolon in a file name, you may need to enclose the variable in quotation marks in the Command Parameters box after you insert it from the Context variables box.
Click OK to save the Command.
Add other Actions as needed, and then click Apply to save the Event Rule.