![]() |
If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below. |
|
|
Thread Tools | Search this Thread | Display Modes |
#1
|
|||
|
|||
![]()
I am familiar with some VBA macro writing in Word but no nothing for how to
do this in Outlook. I am trying to accomplish the following: Find all email messages, by conversation, after I reply to a message with a certain phrase and move it to Folder named Completed Work. I attempted to run a rule, but I need to run a script within the rule to complete the "find messages by conversation" part. Can this be accomplished and how? Thanks! |
Ads |
#2
|
|||
|
|||
![]()
You would use a Find or Restrict on the Items collection of each folder
where you wanted to find those related items. The property to filter on is the ConversationTopic property. How you get a folder reference for something like Completed Work depends on where it's located in the folder tree. Let's say the filter is just for Inbox, code would look something like this: Sub GetConversationItems(Item As MailItem) Dim oFolder As Outlook.MAPIFolder Dim colItems As Outlook.Items Dim colFiltered As Outlook.Items Set oFolder = Application.Session.GetDefaultFolder(olFolderInbox ) Set colItems = oFolder.Items Set colFiltered = colItems.Restrict("[ConversationTopic]='" & Item.ConversationTopic & "'") ' now you have the items in that conversation, do something with them End Sub -- Ken Slovak [MVP - Outlook] http://www.slovaktech.com Author: Professional Programming Outlook 2007. Reminder Manager, Extended Reminders, Attachment Options. http://www.slovaktech.com/products.htm "Nagua" wrote in message ... I am familiar with some VBA macro writing in Word but no nothing for how to do this in Outlook. I am trying to accomplish the following: Find all email messages, by conversation, after I reply to a message with a certain phrase and move it to Folder named Completed Work. I attempted to run a rule, but I need to run a script within the rule to complete the "find messages by conversation" part. Can this be accomplished and how? Thanks! |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
Count Messages Per Conversation | [email protected] | Outlook and VBA | 1 | January 16th 08 03:45 PM |
Finding Forwarded Messages | Peter | Outlook - General Queries | 1 | May 2nd 07 01:36 PM |
Macro to clear the old conversation | mrbalaje | Outlook and VBA | 0 | January 1st 07 05:44 AM |
Group messages by conversation, missing in Outlook? | Trond Svendsen | Outlook - General Queries | 3 | November 7th 06 02:08 PM |
Advanced views.."By Conversation". Is it possible to have a view where I see only the first Item of a conversation? | [email protected] | Outlook - General Queries | 2 | February 1st 06 09:41 PM |