ShockUK
asked on
Outlook Rule, just for 1 word in the subject not contains
Hello,
I want to create a rule so e-mails JUST with the word "Start" are forwarded.
So for example if I send an e-mail with the subject "Start" it works the rule
If I send an example with the e-mail subject "The Start" then it won't use the rule
I want to create a rule so e-mails JUST with the word "Start" are forwarded.
So for example if I send an e-mail with the subject "Start" it works the rule
If I send an example with the e-mail subject "The Start" then it won't use the rule
Yes we can do this, are you comfortable and permitted to use VBA?
Chris
Chris
Apologies I wasn't clear, yes we can detect the condition the 'rule' activity will also have to be in teh code but yes within that constraint.
Chris
Chris
ASKER
Yea,
I've used VBA for Excel & Access
I've used VBA for Excel & Access
And for your info it'll look something like:
Chris
Chris
Private Sub Application_ItemSend(ByVal Item As Object, Cancel As Boolean)
If lcase(Item.subject) = "start" Then
' do something with VBA
End If
End Sub
WHat do you want to happen in the specific case that the subject = start>
Chris
Chris
ASKER
Thats great, I will give it ago in the morning.
The the " 'do something with VBA" how would I make it put the e-mail into Folder "Start"
The the " 'do something with VBA" how would I make it put the e-mail into Folder "Start"
Do you want to cancel the send or simply make it save the sent item in the folder start? Also can you identify the path for folder start and i'll put something together:
In outlook put the cursor on the folder start then in the VBE immediate window type:
?application.ActiveExplore r.CurrentF older.Fold erPath
And let me know the path
Chris
In outlook put the cursor on the folder start then in the VBE immediate window type:
?application.ActiveExplore
And let me know the path
Chris
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Modify the line:
Set Item.SaveSentMessageFolder = olNav2Folder("\\Personal Folders\Inbox\Experts Exchange\Answers")
to replace:
\\Personal Folders\Inbox\Experts Exchange\Answers
with the string obtained from the VBE.
Chris
Set Item.SaveSentMessageFolder
to replace:
\\Personal Folders\Inbox\Experts Exchange\Answers
with the string obtained from the VBE.
Chris
Regards.
~coolsport00