Table of Contents

Search

  1. Preface
  2. Introduction
  3. Dashboard
  4. Resources
  5. Workflows
  6. Task Reference
  7. Services Overview
  8. Users
  9. Logs and Reports
  10. Encryption
  11. System
  12. Appendix
  13. Glossary Terms

Example: Iterate Loop

Example: Iterate Loop

A shared folder location is used by several people. You want to process the files at this location, but ignore any files that contain the word 'Payroll' in the file name. In order to ignore files that contain specific text in the file name, you can use a For Each Loop on the File List to iterate through a list of files, and then use the Iterate Loop to skip files that contain the specified text.
  1. Create a File List:
    1. From within the Project Designer page, expand the File System folder in the Component Library, and then drag the Create File List task to the Project Outline.
    2. On the Create File List page, specify the File List Variable, and then specify the File Set that contains the files to process.
    3. Click the
      Add
      button in the page toolbar and select the File Set menu item.
    4. In the File Set page, type the complete directory path to the Base Directory that contains the files or click the icon to browse for the directory.
  2. Create the For Each Loop:
    1. From within the Project Designer page, expand the Loops folder in the Component Library, and then drag the For-Each task to the Project Outline.
    2. Specify the Items Variable and the Current Item Variable for the For Each Loop.
  3. Create the Iterate Loop:
    1. On the For-Each Loop page, click the
      Add
      button in the sub-menu and select the Add Iterate Loop menu item.
    2. On the Iterate Loop page, specify a Condition. If the Condition is met, tasks that follow the Iterate Loop will not be executed, and
      Managed File Transfer
      will iterate to the next file in the loop.
  4. Add additional Tasks (after the Iterate Loop ) to continue to process the files that don't meet the Iterate Loop Condition. For instance, files that do not contain the word 'Payroll' in the file name.
  5. Click Save.

0 COMMENTS

We’d like to hear from you!