I'm looking for a way to monitor a GMail inbox for new e-mails. However, I want to avoid checking every few minutes and I'm looking for some sort of real-time notification. I've noticed that Outlook (and other IMAP-supporting clients) instantly show when there is a new e-mail, but unfortunately all .NET IMAP libraries seem to lack this functionality.
Does anyone know of an IMAP library that has this functionality? Or is there another way to be instantly notified of new message without doing some short-period polling?
Try free .NET library for accessing IMAP server S22.Imap, with IDLE support
You need to handle IMAP IDLE.
This will notify you when new messages arrive, without constant polling (which is bad).
A very good, commercial .NET IMAP library is MailBee.Net. I used it for a small project a while back, and it seemed to handle things very well, and be fairly easy to work with. There may be others - just search in your library for sending the IDLE command or IDLE command handling, and you'll likely find something.
Mail.dll supports IDLE. Here's the simplified sample:
You can download Mail.dll at: http://www.lesnikowski.com/mail/
Also check out my blog for samples.
Please note that Mail.dll is a commercial product that I've created.
@Queops
Here are the reports from 2 online antivirus scanners:
www.viruschief.com
www.virustotal.com
Please note that VirusTotal is using Symantec scanner.