Hello and thanks for reading this.
Im using the code below to send emails. but it only works on the local host. as soon as i upload it it dont work and give me this code.
No connection could be made because the target machine actively refused it 172.17.73.5:587
Mail.cs file code
public static void InvitationMail(string ToEmail, string MailSubject, string Name, string MailMessage)
{
MailMessage msg = new MailMessage();
msg.To.Add(ToEmail);
MailAddress address = new MailAddress("invitation@kone-education.com");
msg.From = address;
msg.Subject = MailSubject;
msg.Body = "Hello " + Name + Environment.NewLine + Environment.NewLine + MailMessage;
SmtpClient client = new SmtpClient("asmtp.unoeuro.com");
client.EnableSsl = true;
...
Go to the complete details ...