Re: Scripting Mail (attempt)
Re: Scripting Mail (attempt)
- Subject: Re: Scripting Mail (attempt)
- From: John Delacour <email@hidden>
- Date: Tue, 29 Apr 2003 12:31:47 +0100
- Mac-eudora-version: 6.0a16
At 10:53 pm +0200 28/4/03, bezoek wrote:
Scripting Mail is very hard. Google comes in handy, and code
snippets can be found on the web. The Mail-part of the script below
worked when part of a droplet, but when used with one or both of the
top two lines balks at adding the attachment. I tried it using the
POSIX path, but to no avail.
tell app "Mail"
{visible:true, content:"", subject:"", sender:"", signature:""}
put the result into the apologyforproperties
set f to {file name:alias "dx:Users:jd:Documents:b.txt"}
tell apologyforproperties
set subject to "Test"
set content to "Here's that file at last..." & return & return
end
set m to make outgoing message with properties apologyforproperties
tell m's content
set madlocation to a reference to after last paragraph
make attachment at the madlocation with properties f
end
end
Or you can try breaking your balls with the official version at
<file:///Library/Scripts/Mail Scripts/Create New Message.scpt>
JD
_______________________________________________
applescript-users mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/applescript-users
Do not post admin requests to the list. They will be ignored.