Solved

how to send mail through c# for authenticated SMTP

Posted on 2004-10-05
5
186 Views
1 Endorsement
Last Modified: 2010-04-07
hi
how to send mail through c# for authenticated SMTP  ?

i have the following code

 SmtpMail.SmtpServer = "xxx.xxxx.xxx.xxx";
               MailMessage oMessage = new MailMessage();
               oMessage.BodyFormat = MailFormat.Text;
               oMessage.Priority = MailPriority.High;
               oMessage.From = "sasi@xxx.com";
               oMessage.To = "xxx@hotmail.com";
               oMessage.Subject = "Test Mail";
               oMessage.Body = "This is a test e-mail";
               SmtpMail.Send(oMessage);

now how to autheticate for the oMessage.From user using this component.

Thanks in advance
Regards,
Sasikumar.
1
Comment
Question by:ravisankar1978
  • 3
5 Comments
 
LVL 20

Expert Comment

by:ihenry
ID: 12226731
What .Net Framework are you working with now?
0
 
LVL 20

Expert Comment

by:ihenry
ID: 12226756
if version 1.1, read this article

SMTP Authentication With The MailMessage Class
http://www.eggheadcafe.com/PrintSearchContent.asp?LINKID=622
0
 
LVL 20

Accepted Solution

by:
ihenry earned 500 total points
ID: 12226776
Or this

SMTP Authentication using System.Web.Mail (CDOSYS)
http://www.codeproject.com/dotnet/SystemWeb_Mail_SMTP_AUTH.asp
0

Featured Post

What is SQL Server and how does it work?

The purpose of this paper is to provide you background on SQL Server. It’s your self-study guide for learning fundamentals. It includes both the history of SQL and its technical basics. Concepts and definitions will form the solid foundation of your future DBA expertise.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
how to gather data from news site 6 32
replace tables with divs, using templates(bootstrap) 9 304
create a website 10 75
USPS CityStateLookup question 3 74
When deciding to adopt any help desk solutions many factors should be explored before taking decisions. This will change from business to another but in general there are some kind of rule of thumb. Here are some quick tips: Do we need only ticket…
Objective of This Article In 1990’s, when I was a budding software professional, I had a lot of confusion about which stream or technology, I had to choose to build my career. In those days, I had lot of confusion like whether to choose System so…
The purpose of this video is to demonstrate how to manually back up a WordPress Database. This will be demonstrated using a Windows 8 PC. The Host used will be IPage.com Log into your Hosting account. IPage will be used for demonstration : Locat…
The purpose of this video is to demonstrate how to update a WordPress Site’s version. WordPress releases new versions of its software frequently and it is important to update frequently in order to keep your site secure, and to get new WordPress…

932 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

15 Experts available now in Live!

Get 1:1 Help Now