Outlook Email Rule execution through shortcut keys (VBA codes)

Status
Not open for further replies.

nbm1515

New Member
Outlook version
Outlook 2016 64 bit
Email Account
Office 365 Exchange
Hi All,

I looking for suggestion for my following VBA code to execute all predefine MS outlook email rules. I have observed email rules can be executed by pressing shortcut keys (Alt+ h + rr + l + r + e + o + c ). However, my following VBA programme does not work well and it leave rule list window open at last. So not sure its works or not.

It would be great help if someone can look into code and help me to execute all email rules through short cut keys

Following VBA macro code open outlook email rule window > select all rules > press run now button > then close rule window > give notification message alert at last

Outlook VBA Code:

Sub SpecialCharExample()
SendKeys "%(h)", True
SendKeys "%(rr)", True
SendKeys "%(l)", True
SendKeys "%(r)", True
SendKeys "%(e)", True
SendKeys "%(o)", True
SendKeys "%(c)", True
SendKeys ("%{TAB}")
SendKeys "%{F4}", True
SendKeys ("{ENTER}")

' tell the user what you did
ruleList = "All rules were executed against the Inbox " & vbCrLf & ruleList
MsgBox ruleList,

End Sub
 
Status
Not open for further replies.
Similar threads
Thread starter Title Forum Replies Date
O Outlook 2016 This rule will only run when you check your email in Outlook.... Using Outlook 4
A Forward Outlook Email by Filtering using Macro Rule Outlook VBA and Custom Forms 44
A Creating an outlook rule to forward an email with a specific message Using Outlook 1
Mary B Outlook 2013: Rule for copying new email to folder & marking that copy as read Using Outlook 1
N Outlook alert/memo/rule when an email does not arrive Using Outlook 3
C Outlook 2007 Removing then adding account restores junk email processing Using Outlook 0
F Wishlist Outlook suddenly began synchronizing deleted items every time I delete a single email. Using Outlook 2
HarvMan Toggle between calendar and email in Outlook 365 Using Outlook 12
F Email being marked as Spam by Gmail and not being visible in Outlook Using Outlook 5
G Save and Rename Outlook Email Attachments Outlook VBA and Custom Forms 0
M How to setup outlook after importing old account information - Entering email account info creates with "(1)" after the account! Using Outlook 1
D Outlook launch email showing new unread email in reading pane Using Outlook 11
K Outlook adds space to rows in HTML email signatures viewed on mobile Using Outlook 1
M HTML email signature in Outlook Using Outlook 3
M Respond to Outlook Email Outlook VBA and Custom Forms 0
U Outlook locking up when replying to Email Using Outlook 7
S Unable to extract text from an Outlook email message Using Outlook 2
P Sending email from outlook IMAP to GMAIL where embedded images are added as attachment Using Outlook 1
P i-Phone 6s Plus receiving 2 notifications from Outlook email Using Outlook 1
C WARNING - DO NOT USE AN OUTLOOK.COM ADDRESS FOR GOOGLE ACCOUNT RECOVERY EMAIL Using Outlook 10
M Outlook, send to > mail recipient - results in plain text email Using Outlook 1
M Issue transferring Outlook 2016 email accounts & settings onto new computer Using Outlook 8
S Outlook email to configure setup for each mail Outlook VBA and Custom Forms 1
S Macro to move “Re:” & “FWD:” email recieved the shared inbox to a subfolder in outlook Outlook VBA and Custom Forms 0
A Backup Email Accounts On OutLook For Mac 2016 (Microsoft 365 subscription version) Using Outlook 0
M Outlook 2013 reminder email by using Outlook vba Outlook VBA and Custom Forms 2
D Sending email from Office 365 alias in Outlook Using Outlook 3
L Outlook saved email templates Using Outlook 1
E How to display "Change Folder" in Change Default Email Delivery Location in Exchange Outlook 2016 Using Outlook 1
M Extract all links from Outlook email, send to Excel Using Outlook 2
B Outlook 2003 email sending & receiving suddenly stopped working Using Outlook 3
O Email not leaving Outbox when using Excel VBA to sync Outlook account Outlook VBA and Custom Forms 4
J Outlook Reply > From > Other Email Address... > Address Not Showing in Sent Items... From Email Outlook VBA and Custom Forms 0
Marc2019 Need help please! Cannot Setup my outlook email account on my Mac Outlook 2011 Using Outlook.com accounts in Outlook 2
H In outlook 365 POP mail Inbox, email takes a long time or never arrives. Using Outlook 1
F My hotmail calendar is not syncing with my outlook but my email is Using Outlook 3
9 Outlook 2016 How to save an Outlook attachment to a specific folder then delete the email it came from? Using Outlook 1
C Outlook Autocomplete suggestions showing wrong person's name against an email address Using Outlook 0
T Outlook converts sent email to txt attachments when sync Using Outlook 0
glnz How set up new IMAP on Outlook-Office 365 and merge in pst from Outlook 2003 for same two email accounts? Using Outlook 5
N Outlook 365 Email Notifications Using Outlook 0
A Outlook 2019 having issues with 'people search' and not making suggestions in email To: etc Using Outlook 12
M Outlook email window maximizes improperly Using Outlook 3
D Adding Enterprise Exchange Email Account to Outlook Prevents Sending via Outlook.com Account Using Outlook.com accounts in Outlook 10
C Outlook Mobile app email order randomized and display names stripped Using Outlook 6
P Insert link in email body to attached document in Outlook 365 Outlook VBA and Custom Forms 0
F Gantt chart or heat map of Outlook/email activity Using Outlook 1
S Outlook 2007 printing wrong email address at top of page Using Outlook 8
D Outlook 2007 crashes when opening an email Using Outlook 2
J VBA Outlook : Subject line : Cut and Paste name to heading , number to very end of the body of Email Outlook VBA and Custom Forms 1

Similar threads

Top