Jump to content
floriansebastien

Simple workflow to create a new email with hotkey

Recommended Posts

Nice! Instead of a hotkey, I rather set the keyword "email", with optional argument. That way I can still look for a recipient in my address book, but in case he's not registered, your workflow open the blank email. Super efficient!

Share this post


Link to post

Sorry to resurrect this old post, but does anyone have this workflow or an alternative that does the same thing?

 

I made you one Workflow that creates a New Blank Mail here: https://www.dropbox.com/s/f9h4ewrhsbyqsiv/Create%20New%20Blank%20Mail.alfredworkflow?dl=0

Could change preferences for it, but i guess this is what you wanted.

 

In case the link would die, here is the Applescript:

tell application "Mail"
   make new outgoing message
end tell

To add preference it has to be like this:

tell application "Mail"
   make new outgoing message with properties {visible:true, subject:"My Subject", content:"My Body"}
end tell

Found it here: http://www.mactech.com/articles/mactech/Vol.21/21.09/ScriptingMail/index.html

 

If you want you could also do this with a query to define directly your Subject, Content etc.

 

Hope this helps you :)

Edited by FroZen_X

Share this post


Link to post

If Mail.app isn't your thing, this should work with whatever you have set as your default client:

tell application "System Events" to open location "mailto:"

Definitely works with Mail.app, Outlook, Airmail 2, MailMate. Does not work with Mail Pilot.

Share this post


Link to post
on alfred_script(q)
  	tell application "Mail"
   		make new outgoing message
	end tell
end alfred_script

 

Generally, it's a better idea to ignore the Run NSAppleScript Action and use the normal Run Script Action with language = /usr/bin/osascript (AS) instead.

 

The reason is that Alfred blocks while a Run NSAppleScript is running, so you can't use Alfred, but a Run Script is always run in the background.

Edited by deanishe

Share this post


Link to post

 

Generally, it's a better idea to ignore the Run NSAppleScript Action and use the normal Run Script Action with language = /usr/bin/osascript (AS) instead.

 

The reason is that Alfred blocks while a Run NSAppleScript is running, so you can't use Alfred, but a Run Script is always run in the background.

 

I didn't know that, so thanks for pointing that out :) I changed the workflow and uploaded it again.

Share this post


Link to post

Aside of this, what mail client do you prefer Deanishe ? I was looking for a alternative for apple mail, which would be great and therefore testing Airmail atm.

Share this post


Link to post

MailMate, tbh. Absolute powerhouse of a client and the developer, Benny, is amazing. It's fairly pricey, but Benny has literally spent an afternoon helping me with an issue and made me a special build.

 

That said, I think it has a few problems with Gmail due to Google's non-standard implementation of IMAP.

Share this post


Link to post

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...