Forum Moderators: open

Message Too Old, No Replies

Delivery Receipt with CDOSYS

         

fototex

9:40 am on Jan 23, 2010 (gmt 0)

10+ Year Member



Hi friends,

I am sending an e-mail to my customers who have completed their credit card transaction. Within my e-mail I wish to get the information whether the cdosys e-mail has ben successfully delivered to the mailbox of the customer.
I could not find out the correct line of code to insert into my code.

Here is the code I use for sending the e-mail:
<%
Dim ObjSendMail
Set ObjSendMail = CreateObject("CDO.Message")

ObjSendMail.Configuration.Fields.Item ("http://schemas.microsoft.com/cdo/configuration/sendusing") = 2
ObjSendMail.Configuration.Fields.Item ("http://schemas.microsoft.com/cdo/configuration/smtpserver") ="mail.example.com"
ObjSendMail.Configuration.Fields.Item ("http://schemas.microsoft.com/cdo/configuration/smtpserverport") = 25
ObjSendMail.Configuration.Fields.Item ("http://schemas.microsoft.com/cdo/configuration/smtpusessl") = False
ObjSendMail.Configuration.Fields.Item ("http://schemas.microsoft.com/cdo/configuration/smtpconnectiontimeout") = 60

ObjSendMail.Configuration.Fields.Item ("http://schemas.microsoft.com/cdo/configuration/smtpauthenticate") = 1
ObjSendMail.Configuration.Fields.Item ("http://schemas.microsoft.com/cdo/configuration/sendusername") ="example@example.com"
ObjSendMail.Configuration.Fields.Item ("http://schemas.microsoft.com/cdo/configuration/sendpassword") ="password"
ObjSendMail.bodyPart.Charset = "utf-8"
ObjSendMail.Configuration.Fields.Update

ObjSendMail.To = session("Email")
ObjSendMail.Subject = "Your Example.com Orders"
ObjSendMail.From = "orders@example.com"

ObjSendMail.TextBody = "Order1, Order2... No problems with that part."

ObjSendMail.Send

Set ObjSendMail = Nothing
%>

----------------------------------------------------------

So which code should I insert beginning with "ObjSendMail"

Thank you for your comments.

marcel

10:20 am on Jan 23, 2010 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Here is info on requesting a Read Receipt and a Delivery Status Notification:

[support.microsoft.com...]

fototex

11:50 am on Jan 23, 2010 (gmt 0)

10+ Year Member



Yes I have read that article before. It is the

cdoDSNFailure and
cdoDSNSuccess properties.

But how to use them with the "ObjSendMail." syntax?

Thanks for comments

marcel

3:18 pm on Jan 23, 2010 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



But how to use them with the "ObjSendMail." syntax?

doesn't

ObjSendMail.DSNOptions = cdoDSNSuccessFailOrDelay
work?

fototex

4:23 pm on Jan 23, 2010 (gmt 0)

10+ Year Member




I have used it as it is and tried to send several mails with it.
The mails did arrive as usual, but the code did not inform me with any messages whether the mail has arrived or not.

marcel

4:43 pm on Jan 23, 2010 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



As far as I know, most Mail servers (and users, including myself) disable delivery status and read receipt notifications for privacy and security reasons.

Imagine if a spammer could spam random email addresses, requesting and receiving a Delivery status for each mail. It would be an easy way of getting a list of active email addresses.