Search

GlobalSCAPE Knowledge Base

How do I Configure an Event Rule to Copy/Move a File that is Triggered on a Folder Monitor Event with a Renamed Condition?

Karla Marsh
EFT Express (SMB) & Enterprise

THE INFORMATION IN THIS ARTICLE APPLIES TO:

  • EFT Server (All Versions)

QUESTION

How can I configure an Event Rule to copy/move a file that is triggered on a Folder Monitor event with a Renamed condition?

ANSWER

Use the variable %FS.DST_PATH% instead of %FS.PATH%, and %FS.DST_FILE_NAME% instead of %FS.FILE_NAME%.

If the file is renamed, the new name context is lost to FS.PATH and FS.FILE_NAME, which still retain the old path/name, while the new path/name is passed to %FS.DST_PATH% and %FS.DST_FILE_NAME%.

EXAMPLE

Desired logic:

Monitor Folder()
   if File Change = Renamed Then
            Move renamed file to xyz location
Suppose the monitored folder contained a file called Robert.txt and I rename the file Bob.txt:
%FS.DST_FILE_NAME%
contains the new value Bob.txt, while
%FS.FILE_NAME% 
contains the old value Robert.txt.

If you want to move the modified (renamed) file, use the "DST"-based context variables as shown below, as those contain the modified values.

For version-specific information, refer to the applicable user guide:

v6

v6.1

v6.2

v6.3

v6.4

Details
Last Modified: 7 Months Ago
Last Modified By: kmarsh
Type: HOWTO
Rated 2 stars based on 2 votes.
Article has been viewed 18K times.
Options
Also In This Category
Tags