How to get email from pop.gmail.com using c#?
<p>i want to read email from pop.gmail.com using console application.</p>

<pre><code>Pop3 client = new Pop3();
client.Connect("pop.gmail.com",995);
client.Login("xyz@searce.com", "12345");
//client.IsAuthenticated = true; 

// get message list 
Pop3MessageCollection list = client.GetMessageList();

if (list.Count == 0)
{
    Console.WriteLine("There are no messages in the mailbox.");
}
else 
{
    // download the first message 
    MailMessage message = client.GetMailMessage(list[0].SequenceNumber);

}


client.Disconnect();

        }  
</code></pre>

<p>i got error server has closed the connection.
i have already disable firewall and antivirus.</p>

<p>plz help me.</p>
