51 if (EmailAddress!=string.Empty)
52 {
53 MailMessage mail = new MailMessage(ConfigurationManager.AppSettings["From"], EmailAddress);
54 mail.Subject = "Unpaid PAYMENT REMINDER ";
55 //mail.Body = "Dear distributor,<br/><br/>The payment of Order# " + dr["OrderNo"].ToString() + " has been flagged as not yet Paid. <br/><br/>Please can you make payment and upload the remittence slip.<br/><br/>Kind Regards,<br/><br/>Capital Steel Buildings";
56 mail.Body = "<span " + Constants.EmailMessageNormalStyle + ">Dear distributor,<br/><br/>The payment of Order# <span " + Constants.EmailMessageNumbersStyle + ">" + dr["OrderNo"].ToString() + "</span> has been flagged as not yet Paid. <br/><br/>Please can you make payment and upload the remittence slip.</span><br/><br/><span " + Constants.EmailFixMessageStyle + ">PLEASE DO NOT REPLY TO THIS EMAIL ADDRESS – EMAIL HAS BEEN GENERATED AUTOMATICALLY TO PROVIDE A NOTIFICATION ONLY–<br/>REPLYING TO THIS ADDRESS WILL RESULT IN NO FEEDBACK.</span><br/><br/><span " + Constants.EmailMessageBoldStyle + ">Regards,<br/>Capital Steel Buildings.</span>";
57 mail.IsBodyHtml = true;
58
59 SmtpClient sm = new SmtpClient();
60 NetworkCredential nt = new NetworkCredential("ccs@capitalsteelbuildings.co.uk", "ccs#2009");
61
62 sm.Host = ConfigurationManager.AppSettings["SMTP"];
63 sm.UseDefaultCredentials = false;
64 sm.Credentials = nt;
65
66 if (ConfigurationManager.AppSettings["SendEmail"].Equals("Yes"))
67 sm.Send(mail);
68 }