How to decide if an Outlook message is created by New/Reply/Forwar

  • Thread starter Thread starter X. Zhang
  • Start date Start date
X

X. Zhang

How to decide if an Outlook message is created by New/Reply/Forward in VB?
What I'm trying to do is to list all open outlook messages created by
New/Reply/Forward, which are suppose to be sent out.

Thanks.
 
If the item is a reply or forward it would have a ConversationIndex property
that isn't null. Other than that you'd have to look at the subject and look
for "RE:" or "FW:" or whatever.
 
Thank you for your reply, Ken. But both your suggestions will not work for me:

1) ConversationIndex - yes, it's blank for a New item; but for an existing
item, it always has a value no matter if you created an item by Reply/Forward
an existing one, or opened an existing item by simple double clicking it.
2) "RE:" or "FW:" - a) is not reliable (either the user can modify it at any
time, or it may vary for different languages); b) again, cannot distinguish
an item created by Reply/Forward from an item (may already has RE: or FW: in
the subject) opened by double clicking.

I may not be very clear. What I really want is the way to distinguish the
items created by Reply/Forward, "which are suppose to be sent out" (quoted
from my original post), from the items opened by double clicking, which just
for viewing or printing or whatever purposes.
 
A new forward or reply will have EntryID as null or null string until it's
saved.

There is no real good way to do what you want. You have to live with the
various hacks that are available.
 
Sadly "there is no real good way..." :-(
I think that the EntryID is better solution for me then :-)
Thank you again, Ken.
 
Replies almost always have a Recipients.Count > 0 (a reply with no sender would be rare). Forwards have Recipients.Count = 0.

Received items will have Sent = True.

--
Sue Mosher, Outlook MVP
Author of Microsoft Outlook 2007 Programming:
Jumpstart for Power Users and Administrators
http://www.outlookcode.com/article.aspx?id=54


X. Zhang said:
Thank you for your reply, Ken. But both your suggestions will not work for me:

1) ConversationIndex - yes, it's blank for a New item; but for an existing
item, it always has a value no matter if you created an item by Reply/Forward
an existing one, or opened an existing item by simple double clicking it.
2) "RE:" or "FW:" - a) is not reliable (either the user can modify it at any
time, or it may vary for different languages); b) again, cannot distinguish
an item created by Reply/Forward from an item (may already has RE: or FW: in
the subject) opened by double clicking.

I may not be very clear. What I really want is the way to distinguish the
items created by Reply/Forward, "which are suppose to be sent out" (quoted
from my original post), from the items opened by double clicking, which just
for viewing or printing or whatever purposes.

Ken Slovak - said:
If the item is a reply or forward it would have a ConversationIndex property
that isn't null. Other than that you'd have to look at the subject and look
for "RE:" or "FW:" or whatever.

--
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


X. Zhang said:
How to decide if an Outlook message is created by New/Reply/Forward in VB?
What I'm trying to do is to list all open outlook messages created by
New/Reply/Forward, which are suppose to be sent out.

Thanks.
 
Thanks Sue. "Sent" should work for me.

Sue Mosher said:
Replies almost always have a Recipients.Count > 0 (a reply with no sender would be rare). Forwards have Recipients.Count = 0.

Received items will have Sent = True.

--
Sue Mosher, Outlook MVP
Author of Microsoft Outlook 2007 Programming:
Jumpstart for Power Users and Administrators
http://www.outlookcode.com/article.aspx?id=54
 
Back
Top