• Subject: Get image content ID from MAPI mail
  • Author: Tora
  • Date: 20 Nov 2009
  • References:
Hi all,

I have got Outlook 2003 with an eMail that contains embedded pictures. I
need to read these eMails and their attachments including the Content ID.
I did already search the internet for a solution but could not find a
working solution so far. I do know that at a certain point in the
attachment there is written PR_ATTACH_CONTENT_ID / 0x3712001E) but I do
not know how to use this. I really hope that somebody can help me with
this problem. This is my programmed code that I do test at the moment. I
did define a special mailbox with folders in Outlook:

Private Function myModerator_OneFolder()
modname = "test user"
modmailaddr = "test@intern.local"
Postfach = "Postfach - Moderator, Mail"
Verzeichnis = "___Abgelehnt"
wegschicken = True
SubjZus = "Mail OK:"
ErrSubjZus = "Mail NOK:"

Dim fehler, wgfehler, respfehler, readfehler As Boolean

Set Folder =
Application.GetNamespace("MAPI").Folders.Item(Postfach).Folders(Verzeichnis)
Set GesFolder =
Application.GetNamespace("MAPI").Folders.Item(Postfach).Folders(Verzeichnis).Folders("Gesendet")


For i = Folder.Items.Count To 1 Step -1
Set from_Item = Folder.Items(i)
If from_Item.SenderEmailType = "SMTP" Then



For Each objSAttach In from_Item.Attachments
' >>>>>>>>>>>> How can I read out the content ID here?

Next
End If

Next 'mail
myModerator_OneFolder = True
Exit Function
End Function


Big big Thanks for help.

Best regards,
Tora
20 Nov 2009Get image content ID from MAPI mail.Tora
20 Nov 2009\ Re: Get image content ID from MAPI mail.Michael Bauer [MVP - ...
23 Nov 2009   \ Re: Get image content ID from MAPI mail.Tora
23 Nov 2009      \ Re: Get image content ID from MAPI mail.Michael Bauer [MVP - ...
24 Nov 2009         \ Re: Get image content ID from MAPI mail.Tora
24 Nov 2009            \ Re: Get image content ID from MAPI mail.Michael Bauer [MVP - ...
Contact Us
All times are in (US) Eastern Daylight Time (GMT -4:00)