Use the Copy Desktop file action to copy an existing file from Desktop to another location. Optionally, filter by file size or date to control which files are copied.
Procedure
- In the Actions palette, double-click or drag the Copy Desktop file action from the File package.
-
From the Source file field select one of the following
options:
- Specific path: Specify the name and location of the file.
- Regex: Specify the source folder path.
You can use a regular expression (regex) in your source file or folder path to support a pattern-based search. Select the regular expression either as a String or Pattern for each regular expression condition and enter the value.
For example, to copy, delete, rename or print multiple files from your source folder using pattern based search, use regular expressions either as a String and enter the value as My_ for all file name starting with
My_or as a Pattern such as [a-z]{3}(.txt|xlsx) to match files with this pattern.
- In the Destination file/folder field, specify the name of the file and location.
-
Select the Overwrite existing files check box to
overwrite an existing file with the same name at the specified location.
- If the Overwrite existing files option is not selected, the system appends the name of the copied file with a numeric value. For example, if you copy a file named June_Quarter_report.pdf and a file with the same name exists at the destination, the system saves the first copy as Copy of June_Quarter_report.pdf and the second copy as Copy (2) of June_Quarter_report.pdf.
- If the source and destination folders are different, the Overwrite existing files check box is not selected, and a file with the same name exists in the destination, the system displays the following error: Unable to copy file(s) <path\filename> as the specified file(s) exists.
-
Select the Copy multiple files at the same time to increase the copy
speed check box to copy a large number of files simultaneously.
Note: If your existing automations depend on a specific copy speed, adjust your bot code to account for the increased speed before turning on this option.
- Optional:
Select the Size check box to copy a file based on its
size.
-
Select one of the following options from the list:
- Atleast: Copies a file only if the file size is more than the size you have specified.
- Atmost: Copies a file only if the file size is less than the size you have specified.
- Exact: Copies a file only if the file size is the same as the size you have specified.
- Specify a value in the Size field.
-
Select one of the following options from the list:
- Optional:
Select the Date check box to copy a file based on the date
it was created or modified.
-
Select one of the options from the list:
- Created: Copies a file based on the file's creation date.
- Modified: Copies a file based on the date the file was last modified.
-
Select the Is within last option and specify a value
in the field.
Copies the file if it was created or modified within the number of days you specify. For example, entering 7 copies files created or modified in the last 7 days.
-
Select the Is between option to specify a
period.
Enter a Start date and an End date. For example, entering 2019-01-01 as the start date and 2019-01-31 as the end date copies files created or modified within that period.Note: The Start date and End date are included in the period.
-
Select the Is before option and specify a value in the
field.
Copies the file if it was created or modified on or before the date you specify.
-
Select the On a date option and specify a date in the
field.
Copies the file if it was created or modified on the exact date you specify.
-
Select one of the options from the list:
- Click Save.