2

I have been able to send mails from my own domain successfully. My problem now is that I need to access the account and retrieve all the mails that I receive from postmaster and process the information in the mail.

How can I do this? I have been searching the web but could only find solutions involving third party libraries. .NET doesn't bring an inbuild class that helps with this?

Soph
  • 2,895
  • 5
  • 37
  • 68

3 Answers3

1

What type of email server are you working with? If it's exchange, there are some options: Access exchange e-mail in C#

Community
  • 1
  • 1
Billy Coover
  • 3,827
  • 5
  • 36
  • 50
1

First you need to understand what protocols does the Mail Server in question support. You can find this by either reading the help that accompanies it or search in Google for that Mail Server. You may also need to set some settings on the server before you can start coding.

After you understood what protocols your server supports, use some of the following:

If you are using a POP3 server, you may fine the following article useful : A POP3 Client in C# .NET

If you are facing IMAP or Exchange server, you may want to the link that Billy Coover gave you: Read MS Exchange email in C#

Community
  • 1
  • 1
Pavel Donchev
  • 1,809
  • 1
  • 17
  • 29
  • I have access to the webmail however, I have gone through every menu item and failed to find any sign of whether it supports POP3 or IMAP. How could I find out? – Soph Nov 30 '11 at 16:21
  • Strike that, I realized the mail server is an Exchange 2003 server. So the solution you recommend is the one that the second link provides. However, for MS exchange 2003 the proposed solution isn't free. I need a free solution, :S – Soph Nov 30 '11 at 16:54
  • Maybe you should see the answer of the link that Billy Coover gave then? WebDav may be your option. http://msdn.microsoft.com/en-us/library/aa143161%28EXCHG.65%29.aspx – Pavel Donchev Nov 30 '11 at 18:22
  • I followed the link [Read MS Exchange email in C#](http://stackoverflow.com/questions/652549/read-ms-exchange-email-in-c-sharp) and one of the comments to the accepted answer helped me realize this would be MUCH easier configuring this email with Outlook. Now I can do everything I wanted, [this](http://stackoverflow.com/questions/8368380/reading-outlook-mail-with-c-sharp) is how I did it. Thanks!! – Soph Dec 03 '11 at 17:02
1

First you can try to dedect what protocols(IMAP/POP3) supported by remote server. You can try imap_clinet_app.zip or pop3_client_app.zip applications from http://www.lumisoft.ee/lsWWW/download/downloads/Examples/ to connect your server. If you can connect, then specified protocol supported. Both application comes with full source code, so if can use IMAP or POP3, you can use that library in your project.

Ivar
  • 491
  • 3
  • 2