Outlook 2010 - Need help with a custom field.

Status
Not open for further replies.

Farallon5

Member
Outlook version
Outlook 2010 32 bit
Email Account
POP3
Hello!

I use rules a lot. One of my favorite rules is to copy incoming messages to a certain folder and set a No Date follow up flag to appear to show me that that message has a rule applied to it successfully. This way I can tell at a glance which messages have already been filed and I can just delete them from the inbox after I have read them.

Unfortunately, it is cumbersome to see WHERE the message has been filed from the message list if I have a question about it or if I suspect my rule has filed it in the wrong folder.

I can get what I want by right clicking on a message and choosing "Find Related" > "Messages in this conversation" but I would like to add a custom field in a new column that shows me which folders a given flagged message can be found in. Each folder that the message has been copied to by my rule would be shown in the field, separated by a comma. Inbox could be omitted as I am already in the Inbox.

Any help or advice would be appreciated! Thanks!
 

Diane Poremsky

Senior Member
Outlook version
Outlook 2016 32 bit
Email Account
Office 365 Exchange
You might be able to do this using bits from a macro http://www.slipstick.com/outlook/email/sort-messages-sender-domain/ - actually, I think i would copy the message using the macro too, that way you have the folder path to insert into the field. There is a run a script rule at the bottom of the article.

use this to move it, the code on the other macro to set the field.

Dim strFile As String

strFile = "Inbox\Move"

Item.Move (Session.GetDefaultFolder(olFolderInbox).Folders("Move"))
 

Farallon5

Member
Outlook version
Outlook 2010 32 bit
Email Account
POP3
Hi Diane,

I could accept (barely) running a macro to see the folder(s) that my rule directed the message to, but I think running one to do the actual moving, etc would be converting an automatic rule into a manual task. Or am I misunderstanding your suggestion?

Thanks!
 

Diane Poremsky

Senior Member
Outlook version
Outlook 2016 32 bit
Email Account
Office 365 Exchange
Outlook's Rules have an Action called "run a script". Instead of using the rule to move, you'll use the same rule but remove the move Action and add run a script, selecting the move script.

Outlook's Rules and Alerts: Run a Script

Maybe something like this

Public Sub MovedToScript(Item As Outlook.MailItem)
Dim objProp As Outlook.UserProperty
Dim strFile As String
strFile = "Inbox\Move"
Item.Copy (Session.GetDefaultFolder(olFolderInbox).Folders(" Move"))


Set objProp = Item.UserProperties.Add("Copied To", olText, True)
objProp.Value = strFile
Item.Save

End Sub

- - - Updated - - -

Outlook's Rules have an Action called "run a script". Instead of using the rule to move, you'll use the same rule but remove the move Action and add run a script, selecting the move script.


Outlook's Rules and Alerts: Run a Script






Maybe something like this




Public Sub MovedToScript(Item As Outlook.MailItem)



Dim objProp As Outlook.UserProperty
Dim strFile As String
strFile = "Inbox\Move"



Item.Copy (Session.GetDefaultFolder(olFolderInbox).Folders(" Move"))



Set objProp = Item.UserProperties.Add("Copied To", olText, True)
objProp.Value = strFile
Item.Save

End Sub
 
Status
Not open for further replies.
Top