read email Using Pop3 client on asp.net web page
Asked Answered
M

2

8

I want to read Emails through pop3. On my asp.net web page how to do let me know,

which control should I use for showing email?

Meaghanmeagher answered 16/4, 2010 at 9:3 Comment(0)
D
11

Here are a couple of libraries allowing you to retrieve messages from a POP3 server:

Despumate answered 16/4, 2010 at 9:7 Comment(1)
@ Darin Dimitrov ,Can you give me please specific code or url ? I need like as www.pageflakes.com (email widget)Meaghanmeagher
F
0
Dim pop3Client As Pop3Client
Dim i As Integer =1
pop3Client = New Pop3Client
pop3Client.Connect("pop.gmail.com", 995, True)
pop3Client.Authenticate("[email protected]", "mypassword")
Dim inbox_count As Integer = pop3Client.GetMessageCount
Do While (inbox_count >= i)
Dim message As Message = pop3Client.GetMessage(i)
Dim messagePart As MessagePart = message.MessagePart.MessageParts(0)
messagePart.BodyEncoding.GetString(messagePart.Body)'give you message body
message.Headers.From.Address'give you from address
message.Headers.DateSent'date of mail send
message.Headers.Subject'subject of the mail
i= i + 1
Loop
Feliciafeliciano answered 16/4, 2010 at 9:4 Comment(1)
For this answer to be useful, you'd have to be telling people where "Pop3Client" comes from, since it's not a standard ASP.NET class.Arber

© 2022 - 2024 — McMap. All rights reserved.