Click here to Skip to main content
15,889,462 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
i´m using this to get the read/not read notification of a campaign mail.

MailMessage msg = new MailMessage(ece.emailEmisor, destinatario, ece.emailAsunto, ece.emailCuerpo);
msg.Headers.Add("Disposition-Notification-To", "xxxx@xxxx.com");

it's works ok! but then i had to changed to Exchange.

EmailMessage msg = new EmailMessage(ews);
ExtendedPropertyDefinition PidTagReportName = new ExtendedPropertyDefinition(0x003A, MapiPropertyType.String);
ExtendedPropertyDefinition PidTagReportEntryId = new ExtendedPropertyDefinition(0x0045, MapiPropertyType.Binary);
Byte[] ByteVal = HexStringToByteArray("00000000dca740c8c042101ab4b908002b2fe18201000000000000002f6f3d4669727374204f7267616e697a6174696f6e2f6f753d45786368616e67652041646d696e6973747261746976652047726f7570202846594449424f484632335350444c54292f636e3d526563697069656e74732f636e3d656462616e746900");
msg.SetExtendedProperty(PidTagReportEntryId, ByteVal);
msg.SetExtendedProperty(PidTagReportName, "xxxx@xxxx.com");

this code is not working. i don't know how to generate the hex code. the example hex send the mail but not return the confirmation notification.
Posted

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900