0 votes

I am trying to make a web email client as good as outlook. The problem i am facing is :-

1.I can't keep my connection open 24/7 as gmail might not allow.
2.I want to get modified messages after i reconnect to imap. But the code give me
GetFlagsByUID(List) all messages, but i want not all only those which is modified after a timestamp.

Please help me do that.How does other email clients acheive this? If they can do why can't I using mail.dll?

by

1 Answer

0 votes

MODSEQ is not supported by Gmail and probably most other vendors.

Please note that message itself can't be modified, it can be deleted, or have flags changed but the content of the message can't be changed.

Your only option is to query your IMAP server for flags (for example by using Imap.GetFlagsByUID(List ids)) or any attributes you need:
https://www.limilabs.com/blog/get-email-information-from-imap-fast
or by using Imap.Search.

You should probably do that in the background, in batches.

by (301k points)
...