wodImapServer ActiveX Component - Fast notifications interface
 

 

Basic information

As you might have read so far, wodImapServerCom can use fast notification interface instead of firing events. This means that each time wodImapServerCom needs to fire an event, it will call your implementation of the event instead. Notifications can be 30 times faster than events - meaning it is advised to be used if speed is needed in your applications.

wodImapServer ActiveX DOES NOT support notifications - only wodImapServerCom component does!

You must declare ALL notification methods if you want to implement IwodImapNotify, no matter if you need them or not. For example, many users don't need Connecting event, but at least empty body for this event MUST exist when notifications are used.

You can read below steps required to implement your own IwodImapNotify interface. As an example, we will put it on the main form. You can also put it into separate VB class, in which case instead of 'Me' keyword, you will use name of the class.



Steps needed to implement IwodImapNotify

1. Add Reference to wodImapServerCom COM Object to your application

2. Instead of declaring wodImapServer like this:

Dim WithEvents Imap as wodImapServerCom

you should do this:

Dim Imap as wodImapServerCom
Implements IwodImapNotify

3. In Form_Load, create new instance for Imap, and pass reference of our IwodImapNotify to it

Set Imap = new wodImapServerCom
Set Imap.Notification = Me

4. Implement ALL methods, or at least declare their empty bodies. You can do it automatically if you locate 'IwodImapNotify' object in the list of all objects existing on your form (combo box in upper left corner of your code view), or just can do it by hand.

5. All done. Now put breakpoints to your methods. You will see that instead of fired event, your methods will be called instead.



Method declarations

Private Sub IwodImapNotify_Command(ByVal Owner As WODIMAPSERVERCOMLib.IwodImapServerCom, ByVal User As WODIMAPSERVERCOMLib.IImapUser, Command As String)

End Sub

Private Sub IwodImapNotify_Connected(ByVal Owner As WODIMAPSERVERCOMLib.IwodImapServerCom, ByVal User As WODIMAPSERVERCOMLib.IImapUser, ByVal Username As String, ByVal Password As String, Action As WODIMAPSERVERCOMLib.ImapActions)

End Sub

Private Sub IwodImapNotify_Connecting(ByVal Owner As WODIMAPSERVERCOMLib.IwodImapServerCom, ByVal User As WODIMAPSERVERCOMLib.IImapUser, Action As WODIMAPSERVERCOMLib.ImapActions)

End Sub

Private Sub IwodImapNotify_CopyMessage(ByVal Owner As WODIMAPSERVERCOMLib.IwodImapServerCom, ByVal User As WODIMAPSERVERCOMLib.IImapUser, ByVal Folder As WODIMAPSERVERCOMLib.IImapFolder, ByVal Message As WODIMAPSERVERCOMLib.IImapMessage, ByVal Destination As WODIMAPSERVERCOMLib.IImapFolder, Action As WODIMAPSERVERCOMLib.ImapActions)

End Sub

Private Sub IwodImapNotify_CreateFolder(ByVal Owner As WODIMAPSERVERCOMLib.IwodImapServerCom, ByVal User As WODIMAPSERVERCOMLib.IImapUser, ByVal ParentFolder As WODIMAPSERVERCOMLib.IImapFolder, ByVal Name As String, Action As WODIMAPSERVERCOMLib.ImapActions)

End Sub

Private Sub IwodImapNotify_CreateMessage(ByVal Owner As WODIMAPSERVERCOMLib.IwodImapServerCom, ByVal User As WODIMAPSERVERCOMLib.IImapUser, ByVal Folder As WODIMAPSERVERCOMLib.IImapFolder, ByVal Message As WODIMAPSERVERCOMLib.IImapMessage, Action As WODIMAPSERVERCOMLib.ImapActions)

End Sub

Private Sub IwodImapNotify_DeleteFolder(ByVal Owner As WODIMAPSERVERCOMLib.IwodImapServerCom, ByVal User As WODIMAPSERVERCOMLib.IImapUser, ByVal ParentFolder As WODIMAPSERVERCOMLib.IImapFolder, ByVal Folder As WODIMAPSERVERCOMLib.IImapFolder, Action As WODIMAPSERVERCOMLib.ImapActions)

End Sub

Private Sub IwodImapNotify_DeleteMessage(ByVal Owner As WODIMAPSERVERCOMLib.IwodImapServerCom, ByVal User As WODIMAPSERVERCOMLib.IImapUser, ByVal Folder As WODIMAPSERVERCOMLib.IImapFolder, ByVal Message As WODIMAPSERVERCOMLib.IImapMessage, Action As WODIMAPSERVERCOMLib.ImapActions)

End Sub

Private Sub IwodImapNotify_Disconnected(ByVal Owner As WODIMAPSERVERCOMLib.IwodImapServerCom, ByVal User As WODIMAPSERVERCOMLib.IImapUser)

End Sub

Private Sub IwodImapNotify_FlagChange(ByVal Owner As WODIMAPSERVERCOMLib.IwodImapServerCom, ByVal User As WODIMAPSERVERCOMLib.IImapUser, ByVal Folder As WODIMAPSERVERCOMLib.IImapFolder, ByVal Message As WODIMAPSERVERCOMLib.IImapMessage, ByVal NewFlags As WODIMAPSERVERCOMLib.ImapMessageFlags, ByVal OldFlags As WODIMAPSERVERCOMLib.ImapMessageFlags)

End Sub

Private Sub IwodImapNotify_ListFolders(ByVal Owner As WODIMAPSERVERCOMLib.IwodImapServerCom, ByVal User As WODIMAPSERVERCOMLib.IImapUser, ByVal ParentFolder As WODIMAPSERVERCOMLib.IImapFolder)

End Sub

Private Sub IwodImapNotify_ListMessages(ByVal Owner As WODIMAPSERVERCOMLib.IwodImapServerCom, ByVal User As WODIMAPSERVERCOMLib.IImapUser, ByVal Folder As WODIMAPSERVERCOMLib.IImapFolder)

End Sub

Private Sub IwodImapNotify_MoveFolder(ByVal Owner As WODIMAPSERVERCOMLib.IwodImapServerCom, ByVal User As WODIMAPSERVERCOMLib.IImapUser, ByVal ParentFolder As WODIMAPSERVERCOMLib.IImapFolder, ByVal Folder As WODIMAPSERVERCOMLib.IImapFolder, ByVal DestinationFolder As WODIMAPSERVERCOMLib.IImapFolder, ByVal DestinationName As String, Action As WODIMAPSERVERCOMLib.ImapActions)

End Sub

Private Sub IwodImapNotify_MoveMessage(ByVal Owner As WODIMAPSERVERCOMLib.IwodImapServerCom, ByVal User As WODIMAPSERVERCOMLib.IImapUser, ByVal Folder As WODIMAPSERVERCOMLib.IImapFolder, ByVal Message As WODIMAPSERVERCOMLib.IImapMessage, ByVal Destination As WODIMAPSERVERCOMLib.IImapFolder, Action As WODIMAPSERVERCOMLib.ImapActions)

End Sub

Private Sub IwodImapNotify_ReadMessage(ByVal Owner As WODIMAPSERVERCOMLib.IwodImapServerCom, ByVal User As WODIMAPSERVERCOMLib.IImapUser, ByVal Folder As WODIMAPSERVERCOMLib.IImapFolder, ByVal Message As WODIMAPSERVERCOMLib.IImapMessage)

End Sub

Private Sub IwodImapNotify_StateChange(ByVal Owner As WODIMAPSERVERCOMLib.IwodImapServerCom, ByVal User As WODIMAPSERVERCOMLib.IImapUser, ByVal NewState As WODIMAPSERVERCOMLib.ImapUserStates, ByVal OldState As WODIMAPSERVERCOMLib.ImapUserStates)

End Sub

Private Sub IwodImapNotify_SubscribeFolder(ByVal Owner As WODIMAPSERVERCOMLib.IwodImapServerCom, ByVal User As WODIMAPSERVERCOMLib.IImapUser, ByVal Folder As WODIMAPSERVERCOMLib.IImapFolder)

End Sub

Private Sub IwodImapNotify_WriteMessage(ByVal Owner As WODIMAPSERVERCOMLib.IwodImapServerCom, ByVal User As WODIMAPSERVERCOMLib.IImapUser, ByVal Folder As WODIMAPSERVERCOMLib.IImapFolder, ByVal Message As WODIMAPSERVERCOMLib.IImapMessage, Action As WODIMAPSERVERCOMLib.ImapActions)

End Sub