mail script...help needed
mail script...help needed
- Subject: mail script...help needed
- From: Donn Hayes <email@hidden>
- Date: Mon, 27 Aug 2001 15:17:37 -0600
I have a script we have been using just fine with Eudora
I was wondering if I can find some help out there for converting it so
that it works in the Mail application from Apple in OSX. So far I have
had little luck. I am most concerned with the part of the script
following "Tell application Eudora"
Thanks in advance for any pointers anyone can give me here.
the script follows:
---- get the message info from FileMaker
tell application "FileMaker Pro"
--set variables
set messageSubjectData to get cell "invoice ID" of the current record
set messageSubject to "OHCO ORDER #" & messageSubjectData
set messageCompany to get cell "company" of the current record
set messageFirstNameData to get cell "shipping attn" of the current
record
set messageFirstName to "Attn: " & messageFirstNameData
--set messageLastName to get cell "last name" of the current record
set messageShippingAddress to get cell "shipping address" of the
current record
set messageShippingCity to get cell "shipping city" of the current
record
set messageShippingState to get cell "shipping state" of the
current record
set messageShippingZip to get cell "shipping zip" of the current record
set messageLineItems to get cell "line items" of the current record
set messageDate to get cell "Date" of the current record
set messageShipVia to get cell "Ship Via" of the current record
set messageTo to "email@hidden"
set messageBody to "OHCO ORDER #" & messageSubjectData & return &
"Date: " & messageDate & return & ,
"Ship Via: " & messageShipVia & return & return &
messageCompany & return & messageFirstName & return ,
& messageShippingAddress & return & messageShippingCity &
space & messageShippingState & space ,
& messageShippingZip & return & return ,
& "*THIS IS A PACKING SLIP*" & return & ,
"Your invoice and requested promotional materials have been
mailed separately." & return & return & messageLineItems & return &
return ,
& "OHCO/Oriental Herb Company" & return & ,
"P O Box 3141 Evergreen CO 80437-3141" & return & "Phone
303.674.2466 Toll free 800.344.2466" & return ,
& "Fax 303.674.7346 E-mail email@hidden" & return ,
& "Website
http://www.ohco.com"
tell application "Eudora"
activate
set newMsg to make new message at end of mailbox "Out"
set field "to" of newMsg to messageTo
set field "subject" of newMsg to messageSubject
set the body of newMsg to messageBody
end tell
end tell
Donn Hayes