I have searched & searched but have not been able to find the answer to my problem. I am trying to set up a drop button in my application, that will copy files from
one location to a set location. The current code works, but only for the file specified. I want to be able to drop multiple files. Can this be done?
on awake from nib theObject
tell theObject to register drag types {"file names"}
end awake from nib
on drop theObject drag info dragInfo
if "file names" is in types of pasteboard of dragInfo then
set dataTypes to types of pasteboard of dragInfo
if "file names" is in dataTypes then
tell application "Finder"
duplicate file "Macintosh HD:Users:xxx:Desktop:TEST.rtf" to folder "Volume Name:Navigator Test"
end tell
end if
set preferred type of pasteboard of dragInfo to ""
return true
end if
end drop
Thanks
Model: G5 Dual Core, G4 17" Laptop
AppleScript: XCode 3.0
Browser: Firefox 3.0b5
Operating System: Mac OS X (10.5)