Hi Sumanesh
All the NDR are message embeded within a message. You can get idea from the
following code, I have used this methid for forwarding the NDR mail after
reading it.
'Please declare all the variable
'Logged on to the mailbox
'objMsg is the acutal NDR, read from the inbox
Set objForwardMsg = objsess.Inbox.Messages.Add
objForwardMsg.Subject = objMsg.Subject
If objMsg.Attachments.Count > 0 Then
If objMsg.Attachments(1).Type = CdoEmbeddedMessage Then
Set objAttachments = objForwardMsg.Attachments
Set objAttach = objAttachments.Add(objMsg.Subject,
Len(objMsg.Text) + 1, CdoEmbeddedMessage, objMsg.ID)
End If
End If
Set objRecp = objForwardMsg.Recipients.Add 'Recipient
objRecp.Address = "SMTP:" & strMailTo
objRecp.Name = strMailTo
objRecp.Type = mapiTo
objRecp.Resolve
objForwardMsg.Update
objForwardMsg.Send
Hope this code will solve your problem.
Regards
Amitabh
-----Original Message-----
From: Sumanesh Maharabhusanam [mailto:sumaneshm@y...]
Sent: Friday, April 26, 2002 9:16 AM
To: ASP CDO
Subject: [asp_cdo] Problems with NDR
Hi all,
I have got another one problem with the CDO. I dont
know how to view the Non-Deliveery Reports. I can
extract the original mail embeded inside this report,
but i dont know how to display the reason. Please any
one help me. i ve got Exchange Server 2k and Win2k.
thanks in advance,
Sumanesh
__________________________________________________
Do You Yahoo!?
Yahoo! Games - play chess, backgammon, pool and more
http://games.yahoo.com/