# File System Task

The *File System Action* task performs actions on a file or a folder, as it is configured. For example, this task can copy a file, move a file to another folder, or delete all files in a folder.

![](https://750977703-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FqHxyVNGb7tSdIWecl6Ru%2Fuploads%2F5eBzNiNaAOZQUlRHd1FI%2F0.png?alt=media)

To use a *File System Action* task:

1. Drag and drop the *File System Action* object onto the workflow designer. Configure the object by right-clicking on the object’s header and selecting *Properties* from the context menu.

![](https://750977703-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FqHxyVNGb7tSdIWecl6Ru%2Fuploads%2FOJNNK7Nl3j75nQRr1wO6%2F1.png?alt=media)

2. A *File System Action Properties* window will open, as shown below. Here, we will configure the properties of the *File System Action* task.

![](https://750977703-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FqHxyVNGb7tSdIWecl6Ru%2Fuploads%2FrkeSIsIiY0ETWZmlGt1q%2F2.png?alt=media)

3. Select an action from the *Action* dropdown list. The following options are available:
   * *File Copy*: Copies a file from a source folder into a destination folder.
   * *File Move*: Moves a file from a source folder into a destination folder.
   * *File Rename*: Renames a file.
   * *File Delete*: Deletes a file.
   * *Directory Move*: Moves all files in the folder into a new folder
   * *Directory Delete*: Deletes the folder along with any files or folders it contains
   * *Directory Content Delete*: Deletes all files from the folder, leaving the folder empty (the folder itself is not deleted).

<figure><img src="https://750977703-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FqHxyVNGb7tSdIWecl6Ru%2Fuploads%2FCZHB3Iag3WgaD8Q7rqXP%2Fimage.png?alt=media&#x26;token=29097c62-e86d-48d6-9d8a-cc7284a1b398" alt=""><figcaption></figcaption></figure>

The other properties in the *File System Action Properties* window are:

* *Source File (Directory) Path*: Specifies the path to the source file or source directory.
* *Destination Directory Path*: Specifies the path to the destination file or destination folder.
* *Raise Error if no Source File Found*: When checked, return an error message if the source directory is empty.
* *Overwrite Destination*: When checked, overwrites data in the destination file or overwrites files in a destination folder.

<figure><img src="https://750977703-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FqHxyVNGb7tSdIWecl6Ru%2Fuploads%2FoizZYcXLIui2qJ4nkDBy%2Fimage.png?alt=media&#x26;token=e36866b3-edfe-4967-b3bc-855d524e4cfa" alt=""><figcaption></figcaption></figure>
