Get a list of files

Use this step to fetch a list of files

Last published at: February 20th, 2024

getFiles Step

Description:

Gets the list of files in the XML format from a directory on the application server

 

Inputs

  • folderPath – The physical path of the folder on the application server Ex: - C:\Folder1
  • fileScope – File Scope
  • selectSubFolders – Selection of sub folders which are displayed in the main folderEx: - /folder1/folder2
  • variableToStore - variable to store the list of files in XML format
 

 

Returns

  • True – step executed successfully
  • False - step failed to execute
 

 

Usage:

 

 

Example:

Let’s build and execute the getFilesDef example.          

  • Create a new definition called “getFilesDef
  • Select the definition and click the “design” button
  • Drag a “getFiles” step from the toolbox
  • Define a variable/global to store the result
  • Connect the dots between the start and “getFiles” step
  • Click on the “getFiles” step to configure its “Settings” properties. Provide the name to the step. Provide the physical file path on the application server. Provide a variable/global to store the file path in XML format. 
  • Click on the “getFiles” step to configure its “Advanced” properties. Provide the file scope (comma separated for more than one). Select Yes to include the sub-folders. 
  • Save the process definition, generate a new process instance and execute. The process step shall get the list of files and store it in the XML format in the variable/global.