• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: scriptable Mail.app examples
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: scriptable Mail.app examples


  • Subject: Re: scriptable Mail.app examples
  • From: cricket <email@hidden>
  • Date: Wed, 27 Mar 2002 22:45:33 -0800

The problem in your script is that 'to recipient' is an element, not a property, so instead of:

set to recipient of msg to "..."

use this:

tell msg
make new to recipient at beginning of to recipients with properties {display name:"First Last", address:"email@hidden"
end tell

The fact that it returns 0 is a glitch on our part. The 'send' command should have no return value.

- cricket

On Wednesday, March 27, 2002, at 02:03 PM, Derrell Piper wrote:

Anyone have any pointers to sample Mail.app AppleScripts you could point me at?

I'm trying to do something like the following, but the 'send msg' isn't sending (I get a status of '0', which I'm assuming is a failure):

tell application "OmniWeb"
set theLink to address of front browser
set theName to name of front window
end tell
tell application "Mail"
set msg to make new compose message at beginning of every compose message
set content of msg to theLink
set subject of msg to theName
set sender of msg to "..."
set to recipient of msg to "..."
send msg
end tell
_______________________________________________
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.

----->
Software Entomologist/Mail for Mac OS X email@hidden
---------->
If you don't like this email message, write your Congressman
_______________________________________________
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.

References: 
 >scriptable Mail.app examples (From: Derrell Piper <email@hidden>)

  • Prev by Date: Re: [OT] Re: Zoom window / fit screen? How to with applescript?
  • Next by Date: Re: Mount Volume woes
  • Previous by thread: scriptable Mail.app examples
  • Next by thread: AppleScript Pro seminars
  • Index(es):
    • Date
    • Thread