Description:
You can use this widget to fetch the list of files from a folder on the application server.
Inputs
- ID/Name - Name of widget generated by FlowWright (not editable)
- Folder Path - Provide a folder path on the application server
- Include subfolders - Select the checkbox to include the subfolders
- Allow Remove - Select the checkbox to permit the user to remove files from the list during run time
- Read-Only - Select the checkbox to mark the list of files as read-only
- Hide - Select the checkbox to hide the list of files
Design:
![](https://static.helpjuice.com/helpjuice_production/uploads/upload/image/8802/direct/1711005557766-image.png)
Example:
Let’s build and execute the ListFilesFromFolderDef example.
- Create a new form definition called “ListFilesFromFolderDef”
- Select the Open Designer checkbox and click the “Create” button
- Drag a ListFilesFromFolder and Submit button to the canvas.
- Double-click the ListFilesFromFolder to configure the inputs as shown in the below graphic. Provide the folder path on the application server. The folder path can be an absolute, relative, or variable reference. Select the checkbox to include subfolders. Select the checkbox to permit the user to remove files from the list during runtime. Select the checkbox to render the file list as read-only. Select the checkbox to hide the file list during runtime. Click on Save to confirm the configuration.
![](https://static.helpjuice.com/helpjuice_production/uploads/upload/image/8802/direct/1711010885855-image.png)
- Navigate to Run - Form Instances - Create form instance for the above form definition and Edit.
- The form is rendered in a new tab as follows. The list of files from the folder is rendered in a table with a search feature and refresh button. Click the (x) button to remove the file from the list. Click on the file name hyperlink to download the file.
![](https://static.helpjuice.com/helpjuice_production/uploads/upload/image/8802/direct/1711010984136-image.png)
- Click on Submit. The list of files, as per the selection, is stored in the form instance.
- By selecting the subfolders option, the list of files is rendered with the subfolder name, as shown in the graphic below.
![](https://static.helpjuice.com/helpjuice_production/uploads/upload/image/8802/direct/1711017546464-image.png)
- Double-click the ListFilesFromFolder to configure the file path using a relative reference.
![](https://static.helpjuice.com/helpjuice_production/uploads/upload/image/8802/direct/1711018568136-image.png)
- Double-click the ListFilesFromFolder to configure the file path using a variable reference. The variable.filePath is initialized by the process instance before rendering the form.
![](https://static.helpjuice.com/helpjuice_production/uploads/upload/image/8802/direct/1711018600408-image.png)
Globalize:
Double-click the ListFilesFromFolder to configure the Globalize tab, as shown in the graphic below. Select the language from the drop-down list. Click on the Translate button for Azure AI translation.
![](https://static.helpjuice.com/helpjuice_production/uploads/upload/image/8802/direct/1711011627797-image.png)
The translation text may be further modified in the text box to suit the grammar. Click on the Save button to confirm the changes.
![](https://static.helpjuice.com/helpjuice_production/uploads/upload/image/8802/direct/1711011690193-image.png)
Select the culture flag/language in the form designer window. The page is refreshed to render the content accordingly.
![](https://static.helpjuice.com/helpjuice_production/uploads/upload/image/8802/direct/1711011781435-image.png)
Double-click on the ListFilesFromFolder widget. The page is now rendered in the language selected.
![](https://static.helpjuice.com/helpjuice_production/uploads/upload/image/8802/direct/1711014292488-image.png)