Configuration

enaio® 10.10 »

In order to configure enaio® filetrigger, use the command line or the command prompt to go to the System32 directory or the sysWow64 directory and execute the following call:

axFileTrigger.exe -config

The configuration dialog will open.

In the Configuration menu, you can load an existing configuration or save a new configuration. If you select Save configuration, the configuration saved last will be overwritten. If you select Load configuration, your changes will be lost.

You can create a new trigger in the Trigger menu. Every trigger is shown in a separate configuration area in the configuration dialog.

A trigger represents a monitoring scenario. You can create any number of monitoring scenarios. You can create any number of monitoring filters for one monitored directory structure or one monitoring filter for any number of directory structures.

The following specific settings can be made in the configuration dialog:

Monitoring Folder

Specify a monitoring folder to which a trigger will respond to for file system events. With the button next to the text field, you can open the selection dialog to search for a folder.

Include Subdirectories

If this option is enabled, all subdirectories will be monitored as well.

Scan Monitoring Folder on Startup

Enable this option in order to search the monitoring directory immediately after the service is started.

Please note that all file system events to which enaio® filetrigger responds will be recaptured when restarting the service.

Wait until Files are Available

Occasionally, when a file is created by a program it can take some time until the process is completed. If you enable this option, enaio® filetrigger waits until the new file is completely available and only then executes the action configured in the trigger.

Monitoring Filter

Define the files to be affected by the monitoring filter. You can either specify file names or filters. Such filters are common Windows file filters, such as '*.txt*'.

Please note that different Windows operating systems filter in different ways so that the same monitoring filter can lead to different results.

Working Directory

The working directory specifies the directory where the external application is executed. Note that this may affect the proper functionality of the application. If you do not specify a working directory, the directory of the application will be used.

Application

Specify the application which will be started in case of a file system event. It has to be an executable file to which a process can be assigned. If you want to execute a batch file, you need to call it as an argument for the 'cmd.exe' application (see below).

Use the same method to call Visual Basic scripts, specify the VBS host, e.g., wscript.exe, and the \System32 directory as an application and enter the executable VBS file in the Arguments field.

Arguments

Here, you can pass command line parameters to the application. The {file} string will be replaced by the path and the file name for which enaio® filetrigger was triggered. Put {file} in double quotation marks in order to prevent possible conflicts caused by spaces in the path. Also put all additional arguments in double quotation marks.

Please note, that the {file} string is case-sensitive.

Synchronizing

This option allows you to force enaio® filetrigger to execute only one external instance per trigger at a time. If several file events occur in short succession, it may happen that external applications execute a great number of instances.

Timeout

The Timeout option indicates the execution time of the process of an external application (in milliseconds). If the process of the external application exceeds the specified time, it will be terminated and enaio® filetrigger will be executed. The value '0' deactivates this function.

A timeout will only be taken into account if the Synchronize option is enabled.

Use FileTrigger for

You can specify the file system events to which enaio® filetrigger will respond.

Your file and event selection may be affected by the logic of the external application. If an application, for example, deletes or renames the file and you have configured enaio® filetrigger to respond to both file system events, it may happen that enaio® filetrigger responds multiple times.
Therefore it is recommended to analyze the logic of any given scenario and configure the option accordingly.

File Created

enaio® filetrigger reacts if a new file is created that corresponds to the configured filter. The trigger reacts as soon as a new file is recognized. However, file creation may take some time. Therefore, enable the Wait until Files are Available option if you want enaio® filetrigger to wait until the creation of new files is finished.

File Deleted

enaio® filetrigger reacts if a file that corresponds to the configured filter is deleted. It is not ensured that the file is still available at the time of the event. As a consequence, the deleted file may not be available anymore when the specified external application is run.

File Renamed

enaio® filetrigger reacts if a file is renamed. The application will be executed, if the new file name corresponds to the configured filter.

File Modified

enaio® filetrigger is triggered if the modification date of the file is changed.

Streaming operations or nonatomic writing processes may result in inconsistencies when an external application tries to access the file.