OL 2003/2007: HOW allow me to see categories, but not let recipien

C

CuriousGeorge

I want to keep the categories so I could see them on my computer (sort my
Sent messages by category, for example), but that a recipient would NOT
see
it. So it appears the solution I found (the Item.Categories ="") does NOT
accomplish my goal.

Is there a way to do this in OL2003 or OL2007?

DOES OL2007 strip the categories out of emails I send such that a
recipient
will NOT see the categories (in Yahoo email headers, seen as "Keywords")
but
that I can still search the categories after its been sent in the Sent
Items
folder?

And, if OL2007 DOES do this, how can I 'build' such functionality into
OL2003?

(This link *suggests* OL2007 does this, but I question whether it's
correct...

http://blog.clearcontext.com/2007/01/outlook_2007_ca.html )


I had tried popping in this short VBA script in OL2003

Private Sub Application_ItemSend(ByVal Item As Object, _

Cancel As Boolean)

Item.Categories = ""

End Sub

and it took the 'keywords' (categories) out of the recipient's copy of the
email, but it removed the categories from the copy in my Sent folder.

In other words, I do NOT want my recipient to see the categories I assigned
to the email, but I DO want to see the categories assigned (so I can search
for it in my Sent folder later).

Any way to do what I want in OL2003?

Will OL2007 do it? (I really would like to stick with Office 2003!)
 
K

Ken Slovak - [MVP - Outlook]

Outlook 2007 has a rule to strip categories from outgoing emails but it
keeps them in the items in Sent Items, exactly what you want with no code
involved at all.

In Outlook 2003 you'd need to pull the existing categories from the outgoing
items before clearing the categories in the send event. Then you'd need to
handle the ItemAdd() event in the Sent Items folder's Items collection. In
that event you'd check for the subject to make a match to what you saved as
categories from the matching outgoing item and add back the categories.
 
C

CuriousGeorge

Thanks for your reply. It sounds like OL2007 automatically does exactly what
I want. But, since I don't have OL2007....

What code would I write to make OL2003 do what I want?

The code I posted removes the category(s). Is there a way to 1) store the
category(s); 2) set them to "" (as in the code I found on the web); 3) send
the email; 4) reattach the category(s) to the sent message?

I'm not a VBA coder, but I'm thinking the logic would be something like what
follows. Could you write it out as it should be??? Thanks!

Logic, I'm thinking:

Item.Categories = Item.Categories.Old
Item.Categories = ""

Something saying, 'Send email'.

Then, something saying, for the email sent, set
Item.Categories=Item.Categories.Old

I just don't know how to do this. Thanks in advance!
 
K

Ken Slovak - [MVP - Outlook]

I told you what would have to be done:
In Outlook 2003 you'd need to pull the existing categories from the
outgoing
items before clearing the categories in the send event. Then you'd need to
handle the ItemAdd() event in the Sent Items folder's Items collection. In
that event you'd check for the subject to make a match to what you saved
as
categories from the matching outgoing item and add back the categories.

You can look at various code samples at www.outlookcode.com to see how to
handle ItemAdd() events for a folder (see the ZapHTML sample among others)
and to handle the other things I mentioned. For storage just set up global
variables in a code module.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top