I'm working on Visual Basic for Applications code for Outlook to reply to emails that have been moved to a folder called "Reply".
I have it set up a rule to look at the folder when running. Is there a way to modify this code to look at a specific folder?
Option Explicit
Sub ReplyMSG()
Dim olItem As Outlook.MailItem
Dim olReply As MailItem ' Reply
For Each olItem In Application.ActiveExplorer.Selection
Set olReply = olItem.ReplyAll
olReply.HTMLBody = "Hi and thanks for the email" & vbCrLf & olReply.HTMLBody
olReply.Display
olReply.Send
Next olItem
End Sub