I am trying to send an email with attachments which need to be all files in a specific folder.
I have come up with the below but I can figure out how to get x (the incrementing repeat loop variable) into the tAttachments Array...
Code: Select all
set the defaultFolder to specialFolderPath("temporary")
repeat with x =1 to the number of lines of the files
put URL ("binfile:" & specialFolderPath("temporary")&slash&line x of the files) into tAttachments[x]["data"]
put "text/xml" into tAttachments[x]["type"]
set the itemdel to slash
put item -1 of (specialFolderPath("temporary")&slash&line x of the files) into tAttachments[x]["name"]
set the itemdel to comma
end repeat
Code: Select all
put "text/xml" into tAttachments[&x&]["type"]