Author |
|
raindm Groupie
Joined: 31 January 2008 Location: Israel
Online Status: Offline Posts: 44
|
Posted: 28 October 2008 at 7:51am | IP Logged
|
|
|
Hello
I need to handle bounch emails.
I need to get the TrackingID and the error Reason from the bounch emails i recive.
I found that my mail server saves the information regarding the TrackingID and error number in a file attached to the bounch mail that ends with .dat.
I try Using attachedMsg = attach.GetEncapsulatedMessage(); to read this .dat file but it returns NULL..
Is there a way to workaround this issue?
Thanks,
Dror
|
Back to Top |
|
|
Igor AfterLogic Support
Joined: 24 June 2008 Location: United States
Online Status: Offline Posts: 6104
|
Posted: 28 October 2008 at 8:39am | IP Logged
|
|
|
GetEncapsulatedMessage method tries to retrieve MIME (RFC822-compliant) message, but the .dat file doesn't seem to contain it. In case if it's winmail.dat file (MS-TNEF container), the Attachment.GetAttachmentsFromTnef method may be useful for you.
Regards,
Igor
|
Back to Top |
|
|
raindm Groupie
Joined: 31 January 2008 Location: Israel
Online Status: Offline Posts: 44
|
Posted: 28 October 2008 at 9:53am | IP Logged
|
|
|
hi,
i checked its not a MS-tnef attachment.
All i want to do is read the text inside the "Delivery Status Notification (Failure).dat" file
How could it be done?
|
Back to Top |
|
|
Igor AfterLogic Support
Joined: 24 June 2008 Location: United States
Online Status: Offline Posts: 6104
|
Posted: 29 October 2008 at 5:40am | IP Logged
|
|
|
If it's not MIME message, you may use Attachment.GetData method to retrieve content of the file. This method returns a byte array, you may convert it to string using GetString method and parse it to obtain the information you need.
Regards,
Igor
|
Back to Top |
|
|