How do I change the default Junk Mail folder in Outlook?

9

2

I'm using an IMAP mail service (fastmail.fm) which moves Junk email messages to an IMAP folder called "Junk Mail". Outlook archives Junk to "Junk E-Mail".
How do I change Outlook so that it uses the "Junk Mail" folder for Junk instead of the default?

seanyboy

Posted 2009-10-23T08:57:31.397

Reputation: 1 568

Answers

2

It is much easier to Configure fastmail.fm to save probable spam in the Junk E-Mail folder Outlook creates than build a custom Outlook configuration.

  • Login to fastmail
  • Go to Options > Spam/Virus Protection
  • Click on Custom beside Spam Protection
  • Change the destination folder for Probable Spam from Junk Mail to Junk E-Mail and save. Custom Spam Protection Settings

Jeremy W

Posted 2009-10-23T08:57:31.397

Reputation: 3 529

1

First, delete fastmail's "Junk Mail" folder if it currently exists. Then use the instructions below:


Install Collaboration Data Objects. (Note that it won't install directly - the file you downloaded just unpacks the real installer. Annoying.)

In Outlook, open the Visual Basic editor: either Alt+F11, or Tools - Macro - Visual Basic Editor

In the VB window, go to Tools - References, and enable CDO 1.2.1 in the list.

On the tree in left side, open Project1 - Microsoft Office Outlook - ThisOutlookSession, and paste this script (original source) to the window that opens:

Sub CDORenameFolder()
    Dim outlookApp As Outlook.Application
    Dim cdoSession As MAPI.Session
    Dim folder As Outlook.MAPIFolder
    Dim cdoFolder As MAPI.folder
    Dim newName As String

    Set outlookApp = New Outlook.Application
    Set cdoSession = New MAPI.Session
    cdoSession.Logon ShowDialog:=False, NewSession:=False

    Set folder = outlookApp.Session.PickFolder()
    Set cdoFolder = cdoSession.GetFolder(folder.EntryID, folder.StoreID)

    newName = InputBox("Rename '" + cdoFolder.Name + "' to:", "Rename folder", cdoFolder.Name)
    If newName <> "" Then
        cdoFolder.Name = newName
        cdoFolder.Update
    End If

    cdoSession.Logoff
    Set cdoSession = Nothing
    Set outlookApp = Nothing
End Sub

Press F5 (or Run - Run Sub), and run the ThisOutlookSession.CDORenameFolder macro. A folder selection window should pop up. Under your IMAP account, choose the "Junk E-mail" folder (the one created by Outlook) and click OK.

(If you get "User-defined type not defined", then you forgot to install and/or activate CDO.)


Yes, that is exactly why I hate Outlook now.

user1686

Posted 2009-10-23T08:57:31.397

Reputation: 283 655

If I'm reading this correctly -- you're hard-coding the destination folder name into the script, then running the script to pick the source? – afrazier – 2010-12-13T14:09:14.410

@afrazier: My VBScript skills are ... poor. At the time of posting, this is what I had -- copypasta from the Microsoft KB. (It seems I did rewrite the script later; I updated the post.) – user1686 – 2010-12-13T15:02:03.443

Ah, that makes more sense. To be fair to you, if that's what was in the MS KB, that's pretty sad too. – afrazier – 2010-12-13T16:11:50.903

@afrazier: No, it wasn't - the KB has a sane script with everything hardcoded - for quick renaming of all special folders to their original names. (See "original source" link.) – user1686 – 2010-12-14T10:13:53.503

0

There's no way you can do it, but you could create a rule to move junk mail from the folder where they're placed to the default Junk Mail folder.

alex

Posted 2009-10-23T08:57:31.397

Reputation: 16 172