Solved

how to send mail through c# for authenticated SMTP

Posted on 2004-10-05
5
185 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
Comment Utility
What .Net Framework are you working with now?
0
 
LVL 20

Expert Comment

by:ihenry
Comment Utility
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
Comment Utility
Or this

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

Featured Post

What Is Threat Intelligence?

Threat intelligence is often discussed, but rarely understood. Starting with a precise definition, along with clear business goals, is essential.

Join & Write a Comment

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…
Now that Expression Web 4.0 (http://www.microsoft.com/expression/products/Upgrade.aspx) is free if you buy or have the full version of Expression Web 3.0, now is the best time to  migrate from FrontPage to Expression Web (http://www.frontpage-to-exp…
The purpose of this video is to demonstrate how to create a Printer Friendly PDF on a WordPress Page. This will be demonstrated using a Windows 8 PC. Tools Used are Photoshop, Awesome Screenshot” Google Chrome Extension, and SmallPDF.com Log…
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…

763 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

12 Experts available now in Live!

Get 1:1 Help Now