Recently, we have to implement related functions in the system.
First, go online: Visit http://blog.csdn.net/irvine007/archive/2006/02/22/606117.aspx.
Where can I find cdosys. dll?
Answer: cdosys. dll is built in the operating system, under the System32 directory!
Strange, according to the method in the article, I implemented the "delivery receipt" function, but I could not perform "read receipt ".
Then find http://msdn2.microsoft.com/en-us/vbasic/bb630227.aspx authority on msdnArticle
The key here is to set it like this.
Mymailmessage. headers. Add ("disposition-Notification-to", "returnreceipt@return.com ")
I read a lot of online materials. Basically, this method is very authoritative. But I always have problems here.
Summarize my test results. [I use the Notes server, but I have not tested other email servers]
1. In the. NET 1.1 Environment
1) using system. Web. Mail, the receipt function cannot be tested successfully.
2) When using the cdosys. dll component, you can only "receive receipt", but "read receipt" fails.
Ii. In. NET 2.0
Using system. net. Mail of 2.0 and using the method mentioned above, the "read receipt" test failed. However, you can use mail. deliverynotificationoptions = deliverynotificationoptions. onsuccess; to implement the "receive receipt" function.
Finally, with the help of a colleague familiar with the Notes server,
Mail. headers. Add ("returnreceept", "1 ");
The read receipt is successfully implemented ".
Then we tested it in the. NET 1.1 environment and found that it was invalid and could only run normally in the. NET 2.0 Environment.
It took me a whole day to solve this problem and took a lot of detours, leaving them for reference to friends who needed them.