AppleScript Runner Problems?
AppleScript Runner Problems?
- Subject: AppleScript Runner Problems?
- From: "S. J. Cunningham" <email@hidden>
- Date: Mon, 02 May 2011 12:39:12 -0400
I have written a fairly trivial script to compose a new, pre-addressed Mail message and then open it for editing (see attached). The script is based on the "Create New Message" script that ships with the system and is found in the Mail Folder of the Scripts menu. Both my script and the system script frequently - but not always - fail to bring up the new message for editing after running. And there is no new message in the "Drafts" folder. The script appears to exit normally without leaving a trace. Both scripts execute as expected when run from ScriptDebugger.
The only indication of a potential problem I can find is a message in the console log, to wit:
5/2/11 12:16:33 PM /System/Library/CoreServices/AppleScript Runner.app/Contents/MacOS/AppleScript Runner[14530] CPSGetFrontProcess(): This call is deprecated and should not be called anymore.
Maybe it has moved from "deprecated" to "not supported" ?
I'm using Mac OS X 10.6.7 on a MacBook Pro.
BTW, I did notice that several of the draft messages from yesterday showed up in the draft mailbox after I quit and relaunched Mail this morning, but I can't reproduce that either. I rebuilt the Envelope Index file as a precaution but that didn't solve the problem.
Can anyone else verify that this is a problem or suggest a way to troubleshoot it?
Thanks.
Att: My Script:
property freecycleEmail : {name:"Orange County Freecycle", address:"email@hidden"}
property theSender : "email@hidden"
property theSignature : "Freecycle Offer"
property theBody : ""
set theSubject to "OFFER: " & text returned of (display dialog "Freecycle Offer?" default answer "")
tell application "Mail"
activate
set theSignature to signature theSignature -- Don't understand why I have to do this in two steps
set newMessage to make new outgoing message with properties {subject:theSubject, content:theBody}
tell newMessage
set sender to theSender
make new to recipient at end of to recipients with properties freecycleEmail
set message signature to theSignature
set visible of newMessage to true
activate
end tell
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:
Archives: http://lists.apple.com/archives/applescript-users
This email sent to email@hidden