Hello. What i'm trying to achieve is adding an option to Safari for getting the selected text and sending it to Mail as the content of a new email message, along with the website's url. The already available action "New Mail Message" is able to do half of what i'm asking: it can send my selection to Mail as the content of a new emal message, but nothing more. I'm trying to compose an Applescript to run from within my Automator Service, but i'm getting an error:
The action "Run AppleScript" encountered an error.
Any ideas?
Here is the script i'm using:
And here is a screenshot of my Automator Workflow:
The action "Run AppleScript" encountered an error.
Any ideas?
Here is the script i'm using:
Code:
on run {input, parameters}
set myBodyText to value of variable "mySelection" of front workflow
set siteURL to value of variable "mySiteURL" of front workflow
tell application "Mail"
make new outgoing message with properties {visible:true, subject:"Something Interesting", content:"" & siteURL & myBodyText}
end tell
return input
end run
And here is a screenshot of my Automator Workflow: