I was wondering whether i could create inline file attachments for mail. I’m using Mail.app v3.2 and script editor v2.2
I’m able to create attachments after the last paragraph, but now if I want to insert it inline?
Is it possible?
also, i understand that I can change the contents of an outgoing message by doing
set contents of theMessage to “ABC”
but say I want to append to the same contents of the message, what I’ve tried and failed was
tell application "Mail"
set theMessage to make new outgoing message with properties {visible:true}
tell theMessage
set content of theMessage to "ABC"
set content of theMessage to (content of theMessage & "DEF")
end tell
end tell
you can make an attachment after or before every paragraph you want,
like
tell application "Mail"
set theMessage to make new outgoing message with properties {visible:true}
tell theMessage
set content to "ABC"
set content to (get content of theMessage & return & "DEF")
tell content to make new attachment at after first paragraph with properties {file name:(choose file)}
end tell
end tell