Custom Rule - from specific sender which contains...

  • Thread starter Thread starter SDeterman
  • Start date Start date
S

SDeterman

I am looking to create a rule to move messages from my Inbox to a
specificed folder.

The messages will always come from a specific sender but the
recipients will contain different ones but a core group.

I am looking to only move the messages which contain a particular list
of (~10) people and keep all others.

I know little about code but can muddle through it with some
direction.

THe advanced rules would work but the "Sent To:" property only
contains an "OR" statement between users not an "AND" statement.

Any help would be appreciated.
 
Here're the basics you need for a run-a-script rule that works without
blocked properties in OL 2003:

Public Sub MyRule(Item as Outlook.MailItem)
Dim Mail as Outlook.MailItem

With Item
Set Mail=Application.Session.GetItemFromID(.EntryID, .Parent.StoreID)
End With

End Sub

Then work with the Mail variable, and not the Item variable. You can check
its SenderEMailAddress and Recipients collection. To move a message call its
Move function. There's a sample it the VBA help file.

--
Viele Gruesse / Best regards
Michael Bauer - MVP Outlook
The most effective way to assign Outlook categories:
http://www.shareit.com/product.html?productid=300120654&languageid=1
(German: http://www.VBOffice.net/product.html?pub=6)

Am 8 Mar 2007 11:57:08 -0800 schrieb (e-mail address removed):
 
Here're the basics you need for a run-a-scriptrulethat works without
blocked properties in OL 2003:

Public Sub MyRule(Item as Outlook.MailItem)
Dim Mail as Outlook.MailItem

With Item
Set Mail=Application.Session.GetItemFromID(.EntryID, .Parent.StoreID)
End With

End Sub

Then work with the Mail variable, and not the Item variable. You can check
its SenderEMailAddress and Recipients collection. To move a message call its
Move function. There's a sample it the VBA help file.

--
Viele Gruesse / Best regards
Michael Bauer - MVP Outlook
The most effective way to assign Outlook categories:
http://www.shareit.com/product.html?productid=300120654&languageid=1
(German:http://www.VBOffice.net/product.html?pub=6)

Am 8 Mar 2007 11:57:08 -0800 schrieb (e-mail address removed):









- Show quoted text -

Forgive me but I am still stuck, can you be more explicit, i guess my
programming isn't that great after all.
 
I asked you to tell what the problem is. Now I have to guess. Please open
the object browser (f2), switch from <All Libraries> to Outlook and select
MailItem from the left pane. From the right one select the mentioned
properties, Recipients, and SenderEMailAddress, and press f1. It opens a
sample that shows how to work with the properties.

--
Viele Gruesse / Best regards
Michael Bauer - MVP Outlook
The most effective way to assign Outlook categories:
http://www.shareit.com/product.html?productid=300120654&languageid=1
(German: http://www.VBOffice.net/product.html?pub=6)


Am 12 Mar 2007 10:22:36 -0700 schrieb (e-mail address removed):
 
I asked you to tell what the problem is. Now I have to guess. Please open
the object browser (f2), switch from <All Libraries> to Outlook and select
MailItem from the left pane. From the right one select the mentioned
properties, Recipients, and SenderEMailAddress, and press f1. It opens a
sample that shows how to work with the properties.

--
Viele Gruesse / Best regards
Michael Bauer - MVP Outlook
The most effective way to assign Outlook categories:
http://www.shareit.com/product.html?productid=300120654&languageid=1
(German:http://www.VBOffice.net/product.html?pub=6)

Am 12 Mar 2007 10:22:36 -0700 schrieb (e-mail address removed):







- Show quoted text -

The problem is I don't have the background to build this code. Care
to help a guy out and provide a more complete code base?

SD
 
Back
Top