|ReplyAll alerts you before unintentionally replying all, or if you are a confidential BCC recipient of the e-mail.
Determine your preferred settings in the following first function.
Start the macro, for instance, by pressing ALT+F8.
Public Sub RunRules() Dim RunEnabledRules As Boolean Dim RunDisabledRules As Boolean Dim ExecuteOption As Long Dim IncludeSubfolders As Boolean Dim Inbox As Boolean 'Execute the enabled rules (true/false) RunEnabledRules = True 'Execute the disabled rules (true/false) RunDisabledRules = False 'For which messages do you want to run the rules? '0 = all messages '1 = read messages only '2 = unread messages only ExecuteOption = 0 'Start with the Inbox (true) or with the current folder (false) Inbox = True 'Execute the rules only for the start folder (false) or also for its subfolders (true) IncludeSubfolders = False RunRules_ex RunEnabledRules, RunDisabledRules, ExecuteOption, IncludeSubfolders, Inbox End Sub
|Determine the "identity" of your emails. Set with SAM the sender and the folder folder for sent items with the help of rules.
The following part does the job of running the rules. Here you don't need to edit anything.
Private Sub RunRules_ex(ByVal RunEnabledRules As Boolean, ByVal RunDisabledRules As Boolean, _ ByVal ExecuteOption As Long, ByVal IncludeSubfolders As Boolean, ByVal Inbox As Boolean) Dim Store As Outlook.Store Dim Rules As Outlook.Rules Dim Rule As Outlook.Rule Dim Folder As Outlook.Folder If Inbox Then Set Folder = Application.Session.GetDefaultFolder(olFolderInbox) Else Set Folder = Application.ActiveExplorer.CurrentFolder End If Set Store = Application.Session.DefaultStore Set Rules = Store.GetRules For Each Rule In Rules If Rule.RuleType = olRuleReceive Then If Rule.Enabled Then If RunEnabledRules Then Rule.Execute , Folder, IncludeSubfolders, ExecuteOption End If Else If RunDisabledRules Then Rule.Execute , Folder, IncludeSubfolders, ExecuteOption End If End If End If Next End Sub
|VBOffice Reporter is an easy to use tool for data analysis and reporting in Outlook. A single click, for instance, allows you to see the number of hours planned for meetings the next month.