+1 vote

I am trying to make a mail client with mail.dll. I am using POP3 protocol because of common mail server support. I get all mails uid with pop3.getAll() and after checking if the uid does not exists in my database then I get the mail by pop3.GetMessageByUID(uid)
and save it to database.

My problem is that; because of I am not allowed to remove mail from remote mail server;
when i remove a mail from my database and get all mails, the removed mail comes again.

What is the best and optimum solution for this problem.
are there any way for detecting a mail as received before with POP3 protocol except uid.

Any help will be appreciated.

by (250 points)
edited by

1 Answer

0 votes

You must save the information which messages you received.
POP3 server doesn't store this information.

You can learn more about uids in POP3 protocol here:

Please note that some servers behave differently.
For example Gmail and Outlook.com have several POP3 working modes:

by (298k points)
thanks for your answer. I got the idea from your links