In Trigger mode, you can use the File Watcher component to scan a specified directory.
|
|
Search
|
Source Directory Type
|
Select where the directory to be scanned is located:
|
Source Directory
|
Click to create expressions that will support only environment variables and global variables to generate source and destination directory values. The expressions are calculated before a new file is moved to the destination. Click to select the path or address of the directory or folder to be scanned. This button is available only if your source directory is located on a disk.
|
Subdirectory
|
Select this check box, if you want the component to scan all of the selected folder's sub-folders.
|
Filter
|
Enter file filter criteria to limit the files identified by the scanning operation. Click to the right of the field to enter the filter criteria in the Filter dialog box.
You can enter more than one filter criteria, separating them with a comma. For example, *.txt,*.doc.
|
Exclusion Filter
|
Enter the names of files or groups of files that should not be scanned. You can use wildcard characters when entering this criteria. For example, if you want to exclude all files that start with Customer, enter Customer * to indicate all files with the word customer and any other name after. The * wildcard character can be in any position, such as cus*omer.
You can use environment variables in this field with the following syntax:
%[Environment variable name]%
You can enter more than one file, separating them with a comma. For example, *.txt,*.doc.
|
Criteria Filter
|
Select criteria for processing the file in the scanned directory. The options are:
|
Order
|
Select the order for scanning the criteria from the drop-down list. You can select:
|
The order that you define in this property is the order in which files are scanned by the trigger, and not the order in which those files will be processed. To guarantee the order of file processing, enable the Sync Mode (below).
|
|
Operation
|
If you selected Size or TimeStamp in the Criteria field, select the operation criteria from the drop-down list. The options are:
-
Greater than
-
Less than
-
Equal to
|
File Size
|
If you selected Size in the Criteria field, enter the file size in megabytes.
You can use environment variables in this field with the following syntax:
%[Environment variable name]%
|
File TimeStamp
|
This field is shown, if you selected TimeStamp in the Criteria Filter field. Enter the date and time criteria in this property.
|
-
When working with an FTP server, seconds are not considered in the time criteria for the time stamp.
-
Timestamp criteria can be applied on Modified Time value of the files which are moved by the trigger.
|
|
Action
|
File Action
|
Define the action you want the component to perform on the file(s) identified. The options are:
|
Filename Mask
|
Enter the structure for the name of the moved file or the renamed file. You can use wildcard characters. For example:
-
If you want all files to have the file name extension, you can enter *.txt and all files will be saved in the destination directory with their original name and the .txt extension.
-
If you want all files to take only the first two letters of the original name, enter ??.* to create files with their original extension and only the first two letters of the original name.
The Mask property is available when you select Move or Rename as the Action.
Examples:
Enter in Mask: *.txt
Newly created files will be: any name.txt
OR:
Enter in Mask: ??.*
Newly created files will be:
If the original file is Address.txt, then the new file will be Ad.txt
If the original file is Address.doc, then the new file will be Ad.doc
If the original file is Name.txt, then the new file will be Na.txt
|
Destination Directory
|
Click to create expressions that will support only environment variables and global variables to generate source and destination directory values. The expressions are calculated before a new file is moved to the destination. Click to select the path or address of the directory or folder to be scanned.
|
Return Details
|
Return file to
|
Select where the scan file is returned. The file is returned to a BLOB variable defined by the user or a User BLOB.
Click to open the Variable list, and select where to return the file.
|
Return destination file name to
|
Select where the scan file name is returned to. The file name is returned to an Alpha variable.
Click to open the Variable list, and select where to return the file name.
|
Return source file name to
|
Select the original file that was copied/moved. The file name is returned to an Alpha variable.
Click to open the Variable list, and select where to return the file name.
|
Return arguments XML to
|
Select the location for the Arguments XML. The file is returned to a BLOB variable.
Click to open the Variable list, and select the required location.
|
General
|
Synchronous Mode
|
This check-box will control the trigger behaviour. When the check-box is checked, it will enable the synchronous mode and the trigger will process only one file at a time. This mode guaranties the ordered delivery of scanned files. It may result in reduced performance as it is single-thread in nature.
The default mode is async.
(Since version: 4.13.3)
|
Keep Alive Interval
|
The amount of time in minutes after which the unresponsive trigger will be automatically restarted. The default value is 0, which means that the trigger will perpetually wait for the response.
|
You should be very careful when selecting a value for this parameter. If the chosen value is too small, a trigger may terminate before it completes a valid operation.
|
|
Polling Interval
|
Enter the time interval (in milliseconds) that the File Watcher will use to scan directories. For example, if you enter 1000 milliseconds, the File Watcher will scan the directory every second.
|
FTP Transfer Mode
|
This property is available only when the Source Type at the resource configuration level is selected as FTP.
It lets you determine in which format your files are transferred. The choices are Binary or ASCII.
|