Ureader.com  
Microsoft software help and Community
   home   |   control panel login   |   archive   |  
 
Exchange
2000.active.directory
2000.admin
2000.announcements
2000.app.conversion
2000.applications
2000.clients
2000.clustering
2000.connectivity
2000.development
2000.documentation
2000.general
2000.information.store
2000.interop
2000.kms
2000.misc
2000.protocols
2000.realtime.collabo.
2000.setup
2000.transport
2000.win2000
admin
application.conversion
applications
clients
clustering
connectivity
design
development
misc
mobility
setup
tools
  
 
date: Wed, 18 Jan 2006 00:08:03 -0800,    group: microsoft.public.exchange2000.development        back       


How to detect bounce back email original contents?   
Hi,

I am writting a sink for Exchange 2003 that should check the specific user 
account where bounce back emails are return that are not delivered. The email 
contains the original email and any attachment as an attachment to the 
bounced email.

I want to read the orignal email and its headers to get some information. 
How can I do this? I am using C# to read emails from that user account. 

Any Help.

Thanks,
Irfan
date: Wed, 18 Jan 2006 00:08:03 -0800   author:   Irfan

Re: How to detect bounce back email original contents?   
The original message should be an attachment of the NDR message with a 
content type of message/rfc822 so to access the message you can use CDOEX to 
loop though the attachment collection then use the ibodypart interface and 
imessage to open up that attachment as a message eg

eg

set msgobj = createobject("CDO.Message")
msgobj.datasource.open Href,oCon,3
set objattachments = msgobj.attachments
for each objattachment in objattachments
 if objAttachment.ContentMediaType = "message/rfc822" then
      set msgobj1 = createobject("cdo.message")
      msgobj1.datasource.OpenObject objattachment, "ibodypart"
  exit for
 end if
next

msgobj1  would then contain the original message

Cheer
Glen



"Irfan"  wrote in message 
news:DE54D010-2F5E-47FB-B17A-09E2765806F2@microsoft.com...
> Hi,
>
> I am writting a sink for Exchange 2003 that should check the specific user
> account where bounce back emails are return that are not delivered. The 
> email
> contains the original email and any attachment as an attachment to the
> bounced email.
>
> I want to read the orignal email and its headers to get some information.
> How can I do this? I am using C# to read emails from that user account.
>
> Any Help.
>
> Thanks,
> Irfan
date: Thu, 19 Jan 2006 11:28:08 +1100   author:   Glen Scales [MVP]

Google
 
Web ureader.com


    COPYRIGHT 2007, YARDI TECHNOLOGY LIMITED, ALL RIGHT RESERVE  |   contact us