i have created a form and each and every thig is ok.when i am sending message then a runtime error occured So Please Help me.
Code Looks Like this:
MailMessage
msg = new MailMessage();
msg.To.Add(
"my email address");
msg.From =
new MailAddress(txtEmail.Text);
msg.Subject =
"Webhosting Enquiry From " + txtName.Text + " " + txtLastName.Text ;
msg.Body =
"Name: " + txtName.Text + " " + txtLastName.Text + "\nCompany: " + txtCompany.Text + "\nCountry: " + txtCountry.Text + "\nPhone No.: " + txtPhone.Text + "\nDescription:\n" + txtDescription.Text;
SmtpClient email = new SmtpClient("smtp.hosting_company.com");
email.Send(msg);
Error:
The server rejected the sender address. The server response was: 530 5.7.0 Must issue a STARTTLS command first k24sm3179530waf.
Thank's in Advance for Support.