Blog

Managed File Transfer and Network Solutions

Monitor & Respond To Copy File Events | JSCAPE

Posted by John Carl Villanueva on Fri, Mar 06, 2020 @ 03:42 AM

In a previous post, we showed how you can monitor Move File events and respond to them with an appropriate trigger action(s). You can perform these types of operations on Copy File events as well. So, let's say you have a trigger that copies files from the folder C:\sample\testupload to the folder C:\sample\teststorage.

Watch the video  

 

copy file trigger

copy file action parameters

 

If you want a second trigger to respond as soon as the file copy operation completes, you can do that by simply adding a trigger...

 

add trigger with copy file event type

 

... that uses the File Copy event type. 

 

trigger with copy file event type-1

 

In cases where you have several triggers that listen to the File Copy event type and you want this particular trigger to respond only to a particular file copy operation, you can add a corresponding trigger condition. For example, you can add a condition that would let this trigger respond only to those File Copy events whose destination directory is C:\sample\testorage.

 

copy file event trigger condition

 

Once you've specified a trigger condition, you can then proceed and add a trigger action or actions that would execute if the trigger condition evaluates to true. 

Here, in this example, I want this trigger to upload the copied file to a trading partner. To do that, I'll just add the Trading Partner File Upload trigger action...

 

trading partner file upload

 

... select a trading partner to whom I want this file uploaded to, specify the file to upload, which in this case is just the copied file, so I just enter the %DestinationFile% variable, and then specify the remote directory on the trading partner side. 

I then click OK to finalize the trigger creation process. 

 

trigger trading partner file upload action parameters

 

So, when a file is moved to the C:\sample\teststorage directory, that file will be automatically uploaded to the specified trading partner. 

That's it. Now you know how to monitor copied files and respond to a particular file copy event using JSCAPE MFT Server. 

Try this yourself

Would you like to try this yourself? Download the FREE, fully-functional Starter Edition of JSCAPE MFT Server now. 

 

Download Now

 

Topics: JSCAPE MFT Server, Managed File Transfer, Business Process Automation, Tutorials, Triggers