One solution for IMAP message upload issues in Mail

I've been using Mail for a long while with POP accounts. Recently I decided to stop using POP and switch all my accounts to IMAP. I simply disabled my POP accounts (not deleted at all yet) and set up the IMAP ones. Everything worked perfectly until I decided to move important messages from my Mac to the IMAP accounts (you do ithis in the same way as if you where moving messages between different mailboxes). The problem was that moving messages wasn't reliable -- sometimes messages got uploaded, while other times they became grayed out, but nothing happened.After trying several things, including moving them one-by-one (which didn't work either), I found that rebuilding my local mailboxes seems to fix the problem -- as I write this, Mail has uploaded (moved) 350 of 870 messages without any problems.As rebuilding is a per-mailbox thing, I've had to rebuild each local mailbox. I'm guessing that this problem comes from the fact that I've been moving my mailboxes around be...

published on Wednesday, the 12. November 2008, macosxhints

Fix apparently-corrupted PDF attachments in Mail

Lately I'd been having trouble with PDF attachments in Mail -- but only on my MacBook Pro. Instead of seeing a preview of the PDF in the message, I'd see a small black square, maybe 10x10 pixels in size. If I tried to avoid the problem by saving the PDF, the resulting file couldn't be opened in either Preview or Reader; I'd get an error message saying the PDF was corrupt. However, the very same message on my Mac Pro (using IMAP on both Macs, with the message in the inbox) worked perfectly, so I knew it wasn't a problem with the message itself.After pulling my hair out for a while (no luck with Google searches, no Mail plug-ins on either machine, etc.), occasional macosxhints editor Kirk McElhearn suggested a solution that I hadn't even considered: rebuilding the mailbox on the MacBook Pro. Sure enough, after selecting Mailbox » Rebuild, all the troublesome PDF attachments were magically resolved -- previewing and saving both work as ex...

published on Monday, the 10. November 2008, macosxhints

Move Mail messages to IMAP folder via AppleScript

Error messages are sometimes encountered when moving messages to IMAP folders in Mail.app. This is especially annoying when moving large numbers of emails, as Mail then scraps the whole move. The following AppleScript gets around that problem -- it will only leave behind the problematic messages that cause errors.tell application "Mail" set theSelectedMessages to selection repeat with theMessage in theSelectedMessages set theMailbox to "[Gmail]/Sent Mail" tell application "Mail" move the theMessage to mailbox theMailbox of account "Gmail IMAP" end tell end repeatend tellTo use it, just change the account name Gmail IMAP to your account's name, and the folder from [Gmail]/Sent Mail to your IMAP folder's name. (As you can tell, I used this script to upload messages via GMail IMAP.) You can then save the script to your user's Library » Scripts » Applications » Mail folder and run it from the...

published on Tuesday, the 21. October 2008, macosxhints

See on-the-fly 'or' Smart Mailbox views in Mail

As you may be aware, by using the Command key modifier in Mail.app, you can select multiple mailboxes at once. This feature extends Smart Mailboxes, too, and that turns out to be quite useful in some circumstances. For example, I have one Smart Mailbox set up that shows all messages from "John," and another from "Mary", two work colleagues. By selecting both of these mailboxes, I can see all messages from John or Mary, which is often useful. Another possibility would be All Unread Messages with All Today's Messages -- the possibilities are limited only by your imagination, and the scope of your Smart Mailboxes, of course! [robg adds: This is a fast way to build a one-time "or" message list; if you want to build "and" combinations, you'll need to create a new Smart Mailbox set to match "all" following conditions. You can then set the first pop-up field to 'Message is in Mailbox' or '...

published on Thursday, the 16. October 2008, macosxhints

Take advantage of push email servers in Mail.app

This should be manifestly obvious (and that's probably why I couldn't find any documentation for it). But then again, you'd think they would put it in, for instance, Gmail's IMAP setup help page, but it's not...I am sure we all have heard about Push in Apple's Mail by now. For those folks who use email to the point of obsession (I'm afraid I do), this is a great way to keep your mailboxes up-to-the-second current without having Mail.app hog the bandwidth, checking every minute or five minutes. If your server supports IDLE (Gmail, .Mac/MobileMe, and most university servers do), then the only things you need to do are:Go into Mail » Preferences » Accounts (Advanced) and make sure that Use IDLE command if the server supports it is enabled (it's enabled by default).(This is the fun part) Again go into Mail » Preferences » General an...

published on Monday, the 25. August 2008, macosxhints

10.5: Use keyboard shortcuts to file in iTunes and Mail

In, Leopard, it's possible to make a keyboard shortcut for contextual menu items -- for instance, for the Show Package Contents entry in the Finder's contextual menu. This feature can be quite handy in other programs as well, such as Mail or iTunes. In those two programs, I use it for the commands to move messages or songs to mailboxes or playlists. The key is to create a shortcut in Keyboard Shortcuts tab of the Keyboard & Mouse System Preferences panel with the name of the playlist or mailbox you want to move an item into, and choose the appropriate program as the Application. Note that this will only work if your playlist (or mailbox) name is not already a menu item somewhere (so your "Close Window" playlist is out). If you have more than one playlist (or mailbox) of the same name, the fi...

published on Thursday, the 7. August 2008, macosxhints

See Gmail unread message count in Safari's dock icon

If you are like me, you want to keep an eye on your private e-mails even when you're working. In my company, all ports except the ones for FTP and HTTP are blocked, so there's no chance to run e-mail client software such as Mail. I also don't want to log into my mail account every hour (IT/help desk is watching you...), or install a special widget or menulet -- but now I've found a nice way to stay informed about new messages in my Gmail mailbox.The following assumes you have Safari running all the time, and that you're using Gmail (or any other mail account with an RSS feed available).Download the Safari Dock Status SIMBL plug-in. Eventually you have to install SIMBL as well. With the help of SIMBL, you can extend some aspects of Safari (and other applications). Both are free, but install them at your own risk.SIMBL comes with an installer, but th...

published on Wednesday, the 6. August 2008, macosxhints

Mail Saver 3.6.2

Apple's Mail works wonderfully to send and receive messages, but using it for long-term storage of email has undesirable consequences. Mail Saver solves this problem by moving messages into the Finder for long-term storage. It does this by linking mailboxes to Finder folders. When Mail Saver saves the contents of a mailbox, it copies its messages into its linked folder, then moves the original messages to Mail's Trash. The linked folders can be located anywhere you wish, such as with a project, an account or an interest group. Mail Saver simply copies a message without doing any file conversion, thus a saved copy of a message is simply a Mail document (.emlx) file which must be opened with Mail. These saved documents may be Replied, Redirected, Forwarded, Bounced and Printed by Mail just like any other message. (But, they cannot be Junked, Deleted or Flagged). Saved messages also retain attachments, if present. Searching saved messages in Leopard is easy, simply use Spotlight. The saved copy of a message is modified so that: • The file name is the header's subject; • The modification date is the header's Date Sent; and • The comment is the header's To: address (for sent mail) or From: address (for received mail). This allows you to easily identify messages in a List View Finder window. Mail Saver always saves the oldest messages first, so that the Finder shows the most recent messages at the top. Mail Saver uses Apple's Mail as its interface and its action is determined by the mailbox selected in Mail's frontmost Viewer. Here is a brief summary of Mail Saver's features: Linked User Mailboxes — Route messages manually or automatically, using Mail's Rules, to User mailboxes, each linked to a folder. Mail Saver moves the contents of a linked mailbox into its linked folder. The originals are not immediately erased, but are moved into the Trash mailbox. Unread messages are labeled gray and the linked folder is opened showing messages ready to read. Mail Saver Table of Contents — Gives you instant access to Mail Saver, Help, Mail-Safe, (Spot-Mail) and to your linked folders via a menu in the Dock or Script Menu. Save Selected Messages — Selected messages in the Inbox and Sent mailboxes can be saved to any location. The original message is not moved to the Trash mailbox, so you can save multiple copies to multiple locations. Mail-Safe — Creates an archive of every message sent or received by Mail. The Trash mailbox is linked to a 'Mail-Safe' folder of your choice where outdated messages are saved into year-numbered folders containing month-numbered folders containing day-numbered folders. The originals of these messages are erased from Mail. If you have a requirement to maintain an archive of your e-mail, Mail-Safe may meet your needs. Spot-Mail — (Tiger only) Spot-Mail uses Spotlight to search the content of .emlx files in the frontmost folder. (In Tiger, Spotlight cannot search these files directly.)

published on Wednesday, the 16. July 2008, scriptbuilders

Me.com Email Addresses Now Working

If you are a .Mac subscriber, Apple appears to have activated the corresponding @me.com email addresses. If your email address was username@mac.com previously, you can now use username@me.com and emails should arrive in your .Mac mailbox. In the ne...

published on Saturday, the 28. June 2008, macrumors

Use a rule to ignore Gmail spam emails in Mail

I use Mail.app to get my GMail via IMAP. The official recommendations for using GMail this way suggest that I shouldn't let Mail automatically move messages it detects as junk -- because GMail already does most of the legwork for you. I tend to agree, but this is quite frustrating in terms of my other accounts, as this is an application-wide setting.However, there is a solution! By adding a simple mail rule, you can continue to set "Move it to the junk mailbox" in Mail's preferences, but have Mail ignore messages in GMail that it thinks are spam. First, make sure that, in Mail's preferences on the Junk Mail tab, Filter junk mail before applying my rules is unticked. Without this, the rule won't be applied. Now, add a new rule that says:If all of the following conditions are met:Message is Junk MailAccount: GMailPerform the following actions:Stop evaluating rulesAnd there ...

published on Thursday, the 12. June 2008, macosxhints