watchDirectory Help

Help Home
Creating New Tasks
Running Tasks
Task History

Plugins

Standard versus Pro
Version History

Search

See Also...

Supported Plugins




Free 30 day evaluation!
Standard version: $79 USD
Professional version: $149 USD
Buy Now!

 

German Helpfile

German Helpfile

French Helpfile

French Helpfile


Privacy Policy
Run Multiple SubTasks
Warning: deleted files

Take care when deleting files

If you configure a SubTask to delete, move or rename the detected file, subsequent SubTasks may fail.
Tip: chain SubTasks

Tip: Use the output-file of one SubTask as input for another SubTask

While you can not directly use the output of one SubTask as the input for another SubTask, here is a little trick that may help.

Suppose SubTask-1 ZIPs files, and you want SubTask-2 to email that ZIP to someone.

Configure SubTask-1 (the ZIP task) and set its Mask to "*.zip", also click the option so masks have reversed meaning. The effect will be that SubTask-1 will run for all files except ZIPs.

Configure SubTask-2 (the email task) and set its mask to "*.zip". Do not select the "reversed meaning" option.

Run Multiple Tasks for Detected Files

This Plugin is only available in the Professional edition of watchDirectory.

This plugin runs multiple "SubTasks" for detected new and changed files. All SubTasks will be called for the same detected file.

Some benefits of this plugin, compared to running separate tasks, are:

There are a few limitations:

How to run the SubTasks

There are 3 ways you can run the SubTasks:

  1. Run Only 1 SubTask - the First one that Matches
    Each SubTask has 1 or more file-masks (*.doc). If you select this run-mode, at most 1 SubTask will handle the detected file.
    Note that for this run-mode, the order of SubTasks is important.
  2. Run All SubTasks - Stop on Failure
    All SubTasks having a matching file-mask will run for the detected file. When a SubTask fails, other SubTasks will not run.
  3. Run All SubTasks - Continue on Failure
    All SubTasks having a matching file-mask will run for the detected file. When a SubTask fails, other SubTasks will run.

Create a new SubTask

You can create a new SubTask in the following ways:

  1. By Copying the settings of another Task.
    • Select the Task to copy from the "Create new SubTask based on" drop-down
    • Enter a unique SubTask name
    • Press the button labeled "Add"
    The new SubTask will have the plugin settings of the copied Task.
  2. By Copying another SubTask.
    • Select the SubTask to copy
    • Enter a unique SubTask name
    • Press the button labeled "Copy"
    The new SubTask will have the exact same settings as the copied SubTask.
  3. By "Starting Fresh".
    • Select the Plugin to use from the "Create new SubTask based on" drop-down. Their descriptions are displayed in bold.
    • Enter a unique SubTask name
    • Press the button labeled "Add"
    • Make sure to properly configure the new SubTask

After you created the new SubTask, the SubTask Settings window will automatically open. If you used method 3 to create the new SubTask, please make sure to properly configure the Plugin as its settings are now "empty". The other 2 methods will have copied the original plugin settings.

Plugin Notes

A few notes about the supported Plugins.

Automatically Copy Files
If you use this Plugin as a SubTask, and you select the option "remove the file after successful copy", other SubTasks that run after this one will most likely fail as the detected file does not exist anymore. If this is the last SubTask this option causes no problems.

Automatically Delete Files
This Plugin is typically used as the last SubTask. If another SubTask is configured after this, it may fail as the detected file is deleted.

Send Email for Detected Files
Please note that this Plugin only prepares the email to be sent. The real email is sent a bit later by the wdPostman (System.Mail) task. If you configure the email SubTask to attach the detected file and another SubTask is configured to remove the file, even if that SubTask runs after the email SubTask, the detected file may already be removed when the email is sent.
Advise: configure the email SubTask to run as the last SubTask and let the email SubTask remove the file.

Automatically Upload Files
If you select the option Delete the file or Move the file to... for this SubTask, the SubTasks that follow may fail as the detected file is not present anymore.

Rename Files
If you use this plugin, it should typically be configured as the last SubTask. If another SubTask is configured after this, it may fail as the detected file is renamed.

Unzip Files
If you use this Plugin as a SubTask, and you select the option "Delete ZIP file after uncompressing", other SubTasks that run after this one will most likely fail as the detected ZIP file does not exist anymore. If this is the last SubTask this option causes no problems.

Now press next to Configure the Directory to MonitorNext