0 votes


I am using the following code to get only newly received mails from the inbox.

 uidList = imap.Search().Where(

I am getting all the UID's in the uidList after searching, instead of new ones.

Earlier , same code working well. suddenly stopped working.

is the code depends on any email server settings? Please let me know.

I am using licenced copy of mail.dll

Thank you.


1 Answer

0 votes

It's hard to say why you have this problem, especially when you say the code worked before. The question is: what has changed?

Search is always performed by the remote IMAP server. If it returns incorrect results there is nothing you can do, but report the error to the server manufacturer.

Have you checked if all UIDs returned by the server are in-fact greater then the UID you pass to the search (configObj.LargestUID)?

What is the value of configObj.LargestUID? Is it correct?

Is the UIDVALIDITY (FolderStatus.UIDValidity returned by Imap.Select) of the folder same as before?


by (295k points)