Hello,
I'm trying to make a simple rule in OL2016 that will process in outlook, identify certain emails and forward them to a specific address while changing the original subject without FW:
I have this script attached to a rule and it works but when it sends, it adds FW:
Sub ChangeSubjectThenSend()
Dim myolApp As Outlook.Application
Dim aItem As Object
Set myolApp = CreateObject("Outlook.Application")
Set mail = myolApp.ActiveExplorer.CurrentFolder
For Each aItem In mail.Items
aItem.Subject = "OATMEAL"
aItem.Save
Set myForward = aItem.Forward
myForward.Recipients.Add "repository@domain.com"
myForward.Send
Next aItem
End Sub
Any insight would be greatly appreciated!
I'm trying to make a simple rule in OL2016 that will process in outlook, identify certain emails and forward them to a specific address while changing the original subject without FW:
I have this script attached to a rule and it works but when it sends, it adds FW:
Sub ChangeSubjectThenSend()
Dim myolApp As Outlook.Application
Dim aItem As Object
Set myolApp = CreateObject("Outlook.Application")
Set mail = myolApp.ActiveExplorer.CurrentFolder
For Each aItem In mail.Items
aItem.Subject = "OATMEAL"
aItem.Save
Set myForward = aItem.Forward
myForward.Recipients.Add "repository@domain.com"
myForward.Send
Next aItem
End Sub
Any insight would be greatly appreciated!