How to quickly go to and open the folder of searching result in Outlook?
In Outlook, you can search emails based on the specific text with the Searching function. But, if you are searching through all outlook items, you cannot quickly find out the folder of the searching result. In this case, here I have some tricks which can help you quickly go to and open the folder of the searching result.
In Outlook, there is no built-in function can handle this job, except VBA code.
Before using the VBA code, you need to display the folder name in the searched results.
1. Click View > Add Columns.
2. In the Show Columns dialog and in Select available columns from drop-down list, select All Mail fields, then choose In Folder in the Available columns list.
3. Click Add to add In Folders to Show these columns in this order list, then click Move UP button to move In Folder to the top.
4. Click OK to close dialog. Now while you are searching emails, the folder name will be displayed in searching results.
5. Now press Alt + F11 keys to enable Microsoft Visual Basic for Applications window, click Insert > Module to create a new Module.
6. Copy and paste below code into the Module.
VBA: Go to folder by a name
Sub FindFolderByName() 'UpdatebyExtendoffice20181105 Dim xFldName As String Dim xFoundFolder As Folder Dim xYesNo As Integer On Error Resume Next xFldName = InputBox("Folder Name:", "Kutools for Outlook") If Len(Trim(xFldName)) = 0 Then Exit Sub Set xFoundFolder = ProcessFolders(Application.Session.Folders, xFldName) If xFoundFolder Is Nothing Then MsgBox "Not Found", vbInformation, "Kutools for Outlook" Exit Sub End If xYesNo = MsgBox("Activate Folder: " & vbCrLf & xFoundFolder.FolderPath, vbQuestion Or vbYesNo, "Kutools for Outlook") If xYesNo = vbNo Then Exit Sub Set Application.ActiveExplorer.CurrentFolder = xFoundFolder End Sub Function ProcessFolders(Flds As Outlook.Folders, Name As String) Dim xSubFolder As Outlook.MAPIFolder On Error Resume Next Set ProcessFolders = Nothing For Each xSubFolder In Flds If UCase(xSubFolder.Name) = UCase(Name) Then Set ProcessFolders = xSubFolder Exit For Else Set ProcessFolders = ProcessFolders(xSubFolder.Folders, Name) If Not ProcessFolders Is Nothing Then Exit For End If Next End Function
7. Press F5 key to enable the code, now enter the folder name you want to go to into the dialog.
8. Click OK, a dialog pops out to remind you the location of the folder, click Yes to directly go to the folder, or click No to cancel.
If you have Kutools for Outlook, there will be an Open folder utility embed in the right-click menu which can quickly go to the folder of the selected email.
|Kutools for Outlook , Includes 100+ powerful features and tools for Microsoft Outlook 2016, 2013, 2010 and Office 365.
Free install Kutools for Outlook, and then do as below steps:
- Auto CC/BCC by rules when sending email; Auto Forward Multiple Emails by custom; Auto Reply without exchange server, and more automatic features...
- BCC Warning - show message when you try to reply all if your mail address is in the BCC list; Remind When Missing Attachments, and more remind features...
- Reply (All) With All Attachments in the mail conversation; Reply Many Emails in seconds; Auto Add Greeting when reply; Add Date into subject...
- Attachment Tools: Manage All Attachments in All Mails, Auto Detach, Compress All, Rename All, Save All... Quick Report, Count Selected Mails...
- Powerful Junk Emails by custom; Remove Duplicate Mails and Contacts... Enable you to do smarter, faster and better in Outlook.