Re: Filemaker Pro 6 to Mail.app
Re: Filemaker Pro 6 to Mail.app
- Subject: Re: Filemaker Pro 6 to Mail.app
- From: Philip Aker <email@hidden>
- Date: Wed, 21 Aug 2002 08:22:54 -0700
On Wednesday, August 21, 2002, at 06:24 AM, email@hidden wrote:
A simple question (from a newbie), I would like to export my
contacts name, first name, job description and email to Apple
Mail.app in order to send some emails.
I have a script which exports from FM but how do I make a new
mail in Mail.app with Apple Script (and use the informations
from FM) ?
tell application "FileMaker Pro"
set strURL to cell "email" of current record
set strFNAME to cell "fname" of current record
set strLNAME to cell "lname" of current record
set strSUBJ to cell "Job Description" of current record
set strMessage to cell "Message" of current record
set strMAILTO to {strFNAME & " " & strLNAME & "<" & strURL & ">"}
end tell
--Something like this:
set their_email to strURL
set their_name to strFNAME & strLNAME
set msg_subject to strSUBJ
set msg_message to strMessage
tell application "Mail"
activate
try
set this_message to make new compose message at
beginning of every compose message
tell this_message
make new to recipient at beginning of to
recipients with properties {address:their_email, display
name:their_name}
set subject to msg_subject
set content to msg_message
end tell
send this_message
on error errstr
display dialog errstr buttons {"OK"} default button
"OK" with icon note
end try
end tell
--Philip Aker
--
http://www.aker.ca
_______________________________________________
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.