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
Matiki Mahlangu
NA
42
6.5k
Sending Email Using C#
Nov 3 2014 3:21 AM
Hi There
I'm trying to write a code that send email. Created a service, deployed in the server where i have configured the smtp settings.
When sending the email i'm getting the following error and also see the piece of code.
"The remote name could not be resolved. smtp.servername.edu.gov.za"
MailMessage
mail =
new
MailMessage
();
SmtpClient
SmtpServer =
new
SmtpClient
(
"smtp server"
);
mail.From =
new
MailAddress
(
"source"
);
mail.To.Add(
"destination"
);
mail.Subject =
"Testing"
;
mail.Body =
"Awe TestingL"
;
SmtpServer.Port = 25;
SmtpServer.EnableSsl =
true
;
SmtpServer.Send(mail);
MessageBox
.Show(
"mail Send"
);
May you please assist.
Reply
Answers (
2
)
puting value from txt file to process.StandardOutput.Read()
insert data in table in descending order