Skip to content

[Back to Parameters]

File

A widget that allows the user to select a file or folder on the local file system.

Specification

key type required default value description
accessMode enum: 'read', 'write', 'readwrite' yes n/a Indicate if this path represents a path that is a 'source' or a 'destination' or both. This information is used to determine things like which file paths need updating when uploading to FME Server or which files need to be included in a workspace template.
validateExistence boolean yes n/a If true the file or folder must already exist on the filesystem.
itemsToSelect enum: 'files', 'folders', 'filesAndFolders', 'filegeodb', 'esriLayers' yes n/a Specify items to select.
selectMultiple boolean yes n/a If true the browser will allow selection of multiple files and the value will be saved as a list instead of a string.
filters array\<dictionary> no n/a A list of dictionaries of the form (If an empty list is specified all extensions will be selectable.)
includeWebBrowser boolean no false If true show an option to browse web as a filesystem.
allowURL boolean no false If true a URL is a valid replacement for a local path. Note this turns off any path validation.
editable boolean no true Internal only: If false, parameter will not allow editing of the text directly. Browse button will still work, and if any choices are defined they will still be selectable.

deprecated

key type required default value description
separate boolean no false If true allows users to specify a destination filename and optionally a suffix to append to the dataset. Used in FME Quick Translator to translate multiple source datasets into separate destination datasets.

filters

key type required description
filter array\ yes A list of filter strings in *.extension form.
description string yes The description of the filter.

Example

{
  "name": "somefile",
  "type": "file",
  "valueType": "list",
  "prompt": "Files to Read",
  "accessMode": "read",
  "validateExistence": true,
  "itemsToSelect": "files",
  "selectMultiple": true,
  "filters": [
    {
      "filter": ["*.xls", "*.xlsx"],
      "description": "Microsoft Excel Files"
    },
    {
      "filter": ["*.csv"],
      "description": "CSV Files"
    }
  ]
  "includeWebBrowser": true,
  "allowURL": false
}