I've been trying to look for this. Does your client have IDLE / Push capabilities? I am developing an EMS application that receives the dispatches and needs immediate updates from the IMAP server when a message arrives.
Thanks!
I've been trying to look for this. Does your client have IDLE / Push capabilities? I am developing an EMS application that receives the dispatches and needs immediate updates from the IMAP server when a message arrives.
Thanks!
I am not a customer yet. I am part of a volunteer non-profit ambulance company that is using a paid service to receive messages from dispatch. I offered to develop an application that will retrieve the information from the dispatch that is emailed and send it out to our members. Obviously I do not want to spend money on a control to include in my application, but being a VB.Net developer I'm having a hard time finding VB source code that has all of the functions I need. Your control works for NOOPing for new messages, but from what I understand IDLE is a better way to retrieve messages instantly. If there is a version of your control that I can use that will do this requirement, that would be great. Again, all I have to do is "listen" for the new messages, and SMTP them out "parsed" into the necessary information required. No need for folders and real Email client type work. It is a basic "listening" application.
Thanks for the help!
I have added the evenhandler as below. Unfortunately I must be missing something. After logging on, getting emails, and not disconnecting... isn't there a command that I must send to the IMAP server letting it know that I am IDLING? In other words... I'm waiting for a response? As I stated above, I need an immediate response when a message is received. Sending NOOP every now and again doesn't do the same as IDLE. I've tested other clients, and some have this command built in. When a new message has been sent, the update does not get triggered.
Dim
Client As New
ComponentPro.Net.Mail.ImapClient
AddHandler
Client.Update, AddressOf Client_Update
Client.Connect("XXXXXX")
Client.Authenticate("XXXXX", "XXXX")
Dim sb As New ArrayList
Dim
list As MailboxCollection
= Client.ListMailboxes()
For i As Integer = 0 To list.Count - 1
sb.Add("1:
" & list(i).Name)
Next i
Client.Select("INBOX")
listMessages = Client.ListMessages()
For Each m As ImapMessage In
listMessages
ShowUltimateMail(m)
Next m
Public Sub Client_Update(ByVal
Sender As Object,
ByVal e As ComponentPro.Net.Mail.ImapUpdateEventArgs)
'do
something
End Sub