Create new e-mail message with attachment with Sparrow

Jun 19, '12 07:30:00AM

Contributed by: kirkmc

Here is an Automator action I made for creating a new e-mail message with an attachment from the Finder using Sparrow. It is similar to the built-in service for Mail.

Just create a new service, specify that the "Service receives selected: Files or Folders" in "Any Application."

Then, add a "Run Applescript module". Copy and paste the code below.

This works with multiple attachments. Now you should have a contextual menu item after selecting items in the Finder. You can tweak this by opening Keyboard preference pane in System Preferences.

on run {input, parameters}
	tell application "Sparrow Lite" -- or "Sparrow"
		activate
		set theMessage to make new outgoing message
		tell theMessage
			repeat with ii in input
				make new mail attachment with properties {filename:ii as alias}
			end repeat
			compose
		end tell
	end tell
end run
[kirkmc adds: This was submitted by e-mail by Tom F. I don't have Sparrow to test it. One thought: at the beginning, should it really be for "Any Application?" This only works in the Finder, so I think it should be just the Finder in that part of the workflow.]

Comments (3)


Mac OS X Hints
http://hints.macworld.com/article.php?story=20120618013653455