Adding property to attachment via macro

B

BZ

Hey there,

I have a utility (created by someone else in our company) that processes
certain messages. They speak another language and are in another TZ with 6
hours difference so communication is a little tough. :) Their utility
expects the mail item to have a certain message class, and have an
attachment with a certain property on it (which is normally there but on all
but a few). I have written a simple macro to change the message class and
this works. Also I can add the property to the attachment using Outlook Spy,
and then the utility will work fine on the mail item.

Question: Can someone show (or point me to a link) example macro code for
setting a property on an attachment? Doubt it matters for the example, but
the property tag I need to add is 0x370E001E (PR_ATTACH_MIME_TAG).

Thanks!
BZ
 
D

Dmitry Streblechenko

You cannot add that property using the Outlook Object Model, you will need
to use Extended MAPI (C++/Delphi only), CDO 1.21 or Redemption.

Dmitry Streblechenko (MVP)
http://www.dimastr.com/
OutlookSpy - Outlook, CDO
and MAPI Developer Tool
 
B

BZ

Dmitry Streblechenko said:
You cannot add that property using the Outlook Object Model, you will need
to use Extended MAPI (C++/Delphi only), CDO 1.21 or Redemption.

Dmitry Streblechenko (MVP)
http://www.dimastr.com/
OutlookSpy - Outlook, CDO
and MAPI Developer Tool

Ahh crud. Well at least with your 'OutlookSpy' utility Dmitry I can add it
manually for myself. Anyone else at work will just have to fend for
themselves. :) It is a rare thing that this property is missing on said
emails so I don't believe it is worth the effort, by itself, of me learning
the trade.

In case I do find such time, I have two dated books on my shelf here:
1) "Programming Microsoft Outlook and Microsoft Exchange" by Thomas Rizzo
2) "Building Applications with Microsoft Outlook 2000 Technical Reference"
by Randy Byrne (forward by Sue Mosher)

Also a CD labeled "Inside MAPI" by Irving De la Cruz and Les Thaler.

As you can guess, at one time I thought of doing something more advanced but
there just wasn't enough hours in the day as we all know. Are these
resources too dated to be of any use with Outlook 2003/2007?

Thanks,
BZ
 
Top