Home » Questions » Computers [ Ask a new question ]

Outlook keyboard shortcut to move message to a different folder

Outlook keyboard shortcut to move message to a different folder

I am trying to organize my inbox and move my messages to certain folders. Is there a keyboard shortcut I can set up like:

Asked by: Guest | Views: 313
Total answers/comments: 1
Guest [Entry]

"You can create a macro, digital certificate, and assign it to a toolbar button or keyboard shortcut. Check out the information listed here:

http://www.fiftyfoureleven.com/weblog/general/outlook-email-shortcuts

Here's the macro code:

Sub MoveSelectedMessagesToFolder()
On Error Resume Next

Dim objFolder As Outlook.MAPIFolder, objInbox As Outlook.MAPIFolder
Dim objNS As Outlook.NameSpace, objItem As Outlook.MailItem

Set objNS = Application.GetNamespace(""MAPI"")
Set objInbox = objNS.GetDefaultFolder(olFolderInbox)
Set objFolder = objInbox.Folders(""_Reviewed"")
'Assume this is a mail folder

If objFolder Is Nothing Then
MsgBox ""This folder doesn't exist!"", vbOKOnly + vbExclamation, ""INVALID FOLDER""
End If

If Application.ActiveExplorer.Selection.Count = 0 Then
'Require that this procedure be called only when a message is selected
Exit Sub
End If

For Each objItem In Application.ActiveExplorer.Selection
If objFolder.DefaultItemType = olMailItem Then
If objItem.Class = olMail Then
objItem.Move objFolder
End If
End If
Next

Set objItem = Nothing
Set objFolder = Nothing
Set objInbox = Nothing
Set objNS = Nothing
End Sub"