Posted on: 2/11/2015 7:45:40 PM | Views : 518

I'm trying to create something stupid like a form mail...but I've some doubt and lack of experience in creating it in ASP... I tried to find answers here and on other forum, but unsuccessfully...
This is what I'd like to do: create a form mail to double send a feedback to me and a confirmation mail to the users sending me the form.
The code I use is this, with SMTP from Gmail:
using System.Net; using System.Net.Mail; protected void btnSubmit_Click(object sender, EventArgs e) { try { MailMessage Msg = new MailMessage(); // Sender e-mail address. Msg.Headers.Add("From", txtEmail.Text); Msg.From = new MailAddress(txtEmail.Text, "Info From WWW.DOMAIN.IT"); //Msg.Sender = new MailAddress(txtEmail.Text); // Recipient e-mail address. Msg.To.Add("info@MYDOMAIN.IT"); //I'd like to have here an e-mail address different from Gmail, if possible... Msg.Subject = txtSubject.Text; Msg.B ...

Go to the complete details ...