blah blah blah is here! blah blah » Close

up0down
link

Hi,
I'm new to .net. I'm finding difficulty in figuring out how to Import emails from external email servers using C# ... I want to access any extern mail server to import email addresses from it ... Kindly Please guide me !!!
I will really appreciate your help ... Looking forward for your feedback

last answered 2 years ago

1 answers

up0down
link

In the .net framework there is no pop3 mail library.
There is a good pop3 library from you can download from this link:
http://filebeam.com/f10f50075fc49ea6383cd6db411ea4d1
import this library by right clicking on the references folder in the project and clicking add reference, click on browse and selecting the downloaded dll.
Now when you have imported the library use the POP3 class:

DownloadMailTask.POP3Client.POPClient myPopClient = new DownloadMailTask.POP3Client.POPClient();
myPopClient.Connect(host,port);
myPopClient.Authenticate(username, password);
//in myPopClient u can get many things like attachements or the mail itself or the number of mails in your account
int MailMessageCount = 0;
MailMessageCount = myPopClient.GetMessageCount();

This post was imported from csharpfriends, if you have a similiar question please ask it again.

All previous members have been migrated, hope you enjoy the new platform!

Feedback