How to retrieve POP3 emails in VB.Net

.NET programming topics
Post Reply
User avatar
Neo
Site Admin
Site Admin
Posts: 2642
Joined: Wed Jul 15, 2009 2:07 am
Location: Colombo

How to retrieve POP3 emails in VB.Net

Post by Neo » Sun Apr 25, 2010 3:33 am

Add the class attached in the ZIP file to your project and use it as below.

Code: Select all

Dim mail As New Pop3Mail

mail.Connect("mail.xxxx.net", "user", "password")

For Each msg As Pop3Mail.Pop3Message In mail.List

    Trace.WriteLine(DirectCast(mail.Retrieve(msg), Pop3Mail.Pop3Message).message)

Next
Pop3Mail.zip
(1.14 KiB) Downloaded 488 times
LeeShane
Corporal
Corporal
Posts: 3
Joined: Wed Nov 17, 2010 1:17 pm

Re: How to retrieve POP3 emails in VB.Net

Post by LeeShane » Wed Nov 17, 2010 1:55 pm

you can start by first create a new instance of the TcpClient, and attempt to connect to the POP3 server.
Dim tcpClient As New TcpClient()
tcpClient.Connect(fld_Server.Text, Convert.ToInt32(fld_Port.Text))

---------------------------
<link removed>
Last edited by Neo on Wed Nov 17, 2010 3:15 pm, edited 1 time in total.
Reason: Link removed by admin
Post Reply

Return to “.NET Programming”