Posted: Sun Oct 19, 2008 1:39 am Post subject: [ASP.NET] Help request
so.. as part of my project in high school i suppose to build a web site using ASP.NET language with Visual Studio 2003
so i designed a registration WebForm and i want it to send a mail to any1 who will sign into my web
i know how to send a mail through C# (through gmail)
Code:
string host = String.Empty;
host = "SMTP.gmail.com";
MailMessage Mail = new MailMessage();
Mail.To.Add(eMailToSend);
Mail.From = new MailAddress(eMailThatSent);
Mail.Subject = MsgSubject;
Mail.Body = BodyMsg;
SmtpClient SMTP = new SmtpClient(host);
SMTP.Credentials = new System.Net.NetworkCredential(MyUserName, MyPassword);
SMTP.Port = 587;
SMTP.Host = host;
SMTP.EnableSsl = true;
SMTP.Send(Mail);
SMTP = null;
Mail.Dispose();
the only thing is that i can't add System.Net.Mail into my project
and i guess it's because i'm using the 2003 version, cuz when i tried it on 2008 it did add it.
but the problem is that i can't use 2008 to build my project :\
any suggestions? _________________
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum You cannot attach files in this forum You can download files in this forum