Hey All,
Can anyone tell me why when I run this script, I get the message:
The Script is as follows:
global myfolders
global zip_upload
set myfolders to choose folder
set myfolders to result
set zip_upload to ((path to desktop) as string) & "FTP:Sent to FTP"
tell application "Finder"
set all_folders to every folder in myfolders
repeat with a_folder in all_folders
my fileZipper(a_folder)
end repeat
end tell
on fileZipper(a_folder)
if (a_folder as text) ends with ":" then
set myDelimiters to AppleScript's text item delimiters
set AppleScript's text item delimiters to {":"}
set a_folder to (text items 1 thru -2 of (a_folder as text) as text)
set AppleScript's text item delimiters to myDelimiters
end if
set zipFile to (a_folder & ".zip") as text
do shell script "/usr/bin/ditto -c -k -rsrc --keepParent " & (quoted form of (POSIX path of a_folder)) & " " & (quoted form of (POSIX path of zipFile))
return zipFile
end fileZipper
tell application "Finder"
move (files of folder myfolders whose name extension is "ZIP") to zip_upload
end tell
Thanks, any help would be greatly appreciated!
Jase