Click here to Skip to main content
15,889,863 members
Please Sign up or sign in to vote.
1.00/5 (2 votes)
See more:
Is there a possibility if the mail is not answered, it sends a warning
Posted
Comments
bbirajdar 23-Aug-12 4:47am    
No.. I don't think there is such a possibility
Can you explain what exactly you want to do ?
Do you need a fnctionality, where we can send a reminder mail, if the original mail is not read or opened ?
nitin bhoyate 23-Aug-12 7:53am    
I think for this purpose you need to Develope your own email service(like Gmail)
ZurdoDev 23-Aug-12 8:28am    
You can possibly check if it wasn't delivered but I don't think there is any guarantee to know if it has been opened. One method is to put a 1x1 pixel image into it or use something like WebTrends so that when someone does open it, a request is made to your server but if they are reading the email in plain text that won't work.
Yes exactly, you are right ryanb31. The same technique also came to mind, when I saw the question. That is why I was confirming from the OP.
If he confirms that, then we can give him the answer. ;)

1 solution

I would suggest track DeliveryNotification, and give them some time to make reply.
When the time exceeds, send another mail with high priority. This would enable you to confirm delivery of the mail(not sure if the recipient opened or read).

Sample:

C#
//create the mail message
try
{ 
     using(MailMessage mail = new MailMessage())
    {
    //set the addresses
    mail.From = new MailAddress("username@somedomain.com");
    mail.To.Add("recipient@yahoo.com");
    //set the content
    mail.Subject = "This is an email";
    mail.Body = "this is the body content of the email.";
    mail.DeliveryNotificationOptions = DeliveryNotificationOptions.OnSuccess;
    
    //Add "Disposition-Notification-To" for Read receipt
    mail.Headers.Add("Disposition-Notification-To", "<username@somedomain.com>");
     //Set the SMTP server. You can also set the hostname instead of IP Address
    SmtpClient smtp = new SmtpClient("18.204.1.5");    
    
    //Set the user network/domain credentials
    NetworkCredential netCredit = new NetworkCredential("username@somedomain.com", "yourpassword", "DOMAIN");
    
    //Get SMTP to authenticate the credentials
    smtp.Credentials = netCredit;
    
    //Send the e-mail
    smtp.Send(mail);
    }
}
catch (FormatException ex)
{
   //Track  ex.Message
}
catch (SmtpException ex)
{
   //Track  ex.Message
}

Capture/track all exceptions and also track Delivery Failed messages and read reciepts from the inbox set for delivery notification/sender inbox.. Store them in DB/XML etc. Also track the reply for the mail. Now you can easily decide if you need send a warning mail using the data you have captured.

Thanks,

Kuthuparakkal
 
Share this answer
 
v5

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