Apple AppleScript Finder Guide User Manual
Page 127

C H A P T E R 3
Finder Commands
Command Definitions
115
EXAMPLE
This script duplicates a file to a disk, replacing any items at the top level of the
disk that have the same name:
tell application "Finder"
duplicate file "My File" of startup disk ¬
to disk "Backup" replacing conflicts
end tell
You can use replacing existing items, with replacing, or
replacing true
instead of replacing conflicts without changing
the meaning of the script.
NOTES
The statement duplicate items in referenceToContainer (where
referenceToContainer
is a reference to any container) won’t compile. Instead,
use the statement duplicate every item of referenceToContainer.
Eject
3
An Eject command is a request to eject a disk.
SYNTAX
eject [
referenceToDisk ]
PARAMETERS
referenceToDisk
A reference to the disk to be ejected or a list of references.
Class:
Reference or list of references
Default value:
List of references to all mounted disks whose
Ejectable property is true