Files Handling

File Action

The activity allows you to perform basic operations on the document: Copy, Move, Rename, Delete, Make directory.

Depending on the selected action to be performed, appropriate text fields to be filled in will appear in the activity window:

    • when copying and moving documents, fill in the Source and Destination fields with the full path (e.g. Source: C:\Kvasir\The-Art-of-War.pdf; Destination: C:\Users\[user_name]\Desktop\The-Art-of-War.pdf); tick the box to choose overwriting existing file when needed; when folder pointed in Destination does not exist – Wizlink creates it; you can use wildcards in Source textbox (so to move all files to another folder you have to write C:\[directory_tree]\*.*);
    • when renaming documents, fill in the Path and New name fields (e.g. Path: C:\Kvasir\The-Art-of-War.pdf; New name: TheArtofWar.pdf);
    • when deleting documents, fill in the Path field (e.g. C:\Kvasir\TheArtofWar.pdf); you can use wildcards in Path textbox (e.g. C:\Kvasir\*.pdf deletes all PDF files from Kvasir folder);
    • when creating folder, fill in the Path field with the address followed by the name of the directory you want to create (e.g. C:\Mimir).
v2_fh_fileaction
Parameter NameParameter TypeIn/OutDescription
ActionDropdownInputselect action to perform from the dropdown list
Alternative Scenario If FailedBooleanInputcheckbox; default is "on"
DestinationStringInputdirectory path to a file (file name and extension included)
Display NameLiteralInputchanges display name of the activity
Exclude from Transaction CheckBooleanInputcheckbox; default is "off"
New NameStringInputnew name of the file, localization is in File Path (used in: rename)
Overwrite Existing FileBooleanInputcheckbox; default is "off"
PathStringInputdirectory path to a folder
SourceStringInputdirectory path to a file (file name and extension included)
ResultBooleanOutputreturns a Boolean value. True if no error in activity, otherwise will return False
Result CodeInt32OutputResult Code will return 0 if there is no error in activity, otherwise in most cases it will return 1, the extended result code will show only in several chosen activities