forbade Posted March 17, 2008 Share Posted March 17, 2008 Purely Applescript Mail cFunction ( technically this is just a wrapper ) This is the general version, I left out attachments for this version. I should have a multiple attachment work around in the next version. Just pump this cF in the calculation section of the Perform Applescript Script step and your good to go. or just mod the code to be used as a stand alone applescript, *shrugs* either way it works. ______________________________________ Function name : Mail Function Parameters: To // The recipient email address From // The sending account you want to use Subject // Le subject Body // Body of the email Send // if this field = "yes" then it automatically sends the email, useful for mail lists ---------------code "tell application \"Mail\""&¶& " activate"&¶& " set Contact_Email to \""& To &"\""&¶& " set Sending_Account to \""& From &"\""&¶& " set Email_Subject to \""& Subject &"\""&¶& " set Email_Body to \""& ¶& Substitute( Body ;["\"";"\\\""];["\”";"\\\""]) // filters most harmful quotes out of email. &"\""&¶& "set NewEmail to (make new outgoing message with properties {visible:true, subject:Email_Subject, sender:Sending_Account, content:Email_Body})"&¶& "tell NewEmail"&¶& "make new to recipient with properties {address:Contact_Email}"&¶& If ( send = "yes" ; ( "Send" &¶ ) ; "" )& // toggles auto send "end tell"&¶& "end tell" Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.