Apple Mail help sought
Apple Mail help sought
- Subject: Apple Mail help sought
- From: Chuck Stinnett <email@hidden>
- Date: Mon, 31 Jan 2005 12:27:10 -0600
I'm a newspaper reporter with rudimentary (or primitive) Applescript skills.
I'm seeking help modifying a script to work with Apple Mail.
We for several years have used a script (see below) that, in Outlook
Express, would copy the contents of an open OE email message (only one email
message could be open), then create a new file in our editorial word
processing system and insert the contents of the email into that file. (It
also would take the subject of the email message and use that for the slug
line of the newly created story.)
It's a way of turning an email message (such as a letter to the editor) into
a story that's ready to edit.
Now we are transitioning to Apple Mail, and I find that the Mail dictionary
doesn't contain some of the language that OE had.
Can someone advise how to revise this script to instead copy the contents of
an Apple Mail email message so it can be inserted into a story file in
another application?
This seems to be rather a rare task for Applescript, but is exceedingly
useful in our business.
Much obliged,
-- Chuck
tell application "Outlook Express"
-- this routine grabs the text of an email message
set theMessages to the current messages
if the (count of theMessages) > 0 then
repeat with i from 1 to (count of theMessages)
set theSelection to the selection of the front window
if the class of theSelection is not string then set theSelection
to ""
set theMessage to item i of theMessages
set the_text to content of theMessage
set the_name to "From email -- " & subject of theMessage
set fromWho to display name of sender of theMessage
tell application "NewsEditPro IQue"
-- tells the Baseview NewsEditPro application to create a
new story
make new story with properties {slug:the_name, status:"02
Ready to Edit", publication:"Henderson Gleaner"}
--insert stext of email into the new NewsEditPro story
make new text at the beginning of story 1 with data the_text
make new text at the beginning of story 1 with data return
save story 1
end tell
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Applescript-users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden