TECHNOLOGIES
FORUMS
JOBS
BOOKS
EVENTS
INTERVIEWS
Live
MORE
LEARN
Training
CAREER
MEMBERS
VIDEOS
NEWS
BLOGS
Sign Up
Login
No unread comment.
View All Comments
No unread message.
View All Messages
No unread notification.
View All Notifications
Answers
Post
An Article
A Blog
A News
A Video
An EBook
An Interview Question
Ask Question
Forums
Monthly Leaders
Forum guidelines
saranya S
NA
43
56.8k
How to send mail in C# without attachment.
Dec 13 2012 1:08 AM
This s my coding... i cant send mail by using this code. plz help me....
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.Mail;
using System.Net;
public partial class _Default : System.Web.UI.Page
{
protected void Page_Load(object sender, EventArgs e)
{
}
protected void Button1_Click(object sender, EventArgs e)
{
}
public void sendmail(string from, string to, string subject, string body)
{
MailMessage mail = new MailMessage();
mail.From = from;
mail.To = to;
mail.Subject = subject;
mail.Body = body;
mail.Priority = MailPriority.High;
mail.BodyFormat = MailFormat.Text;
SmtpMail.SmtpServer = "192.168.5,11";
SmtpMail.Send(mail);
}
}
Reply
Answers (
4
)
Adding a new row to a databound dataGridView control
connection string problem