wodImapServer ActiveX Component - WriteMessage Method
      
 

Description

Called when user finishes writing new message.


Return Type

None  


Syntax

object.WriteMessage Owner, User, Folder, Message, Action



The WriteMessage Method syntax has these parts:

Part Description
object An expression evaluating to an object of type IwodImapNotify.
Owner Required. A wodImapServer object.
User Required. An ImapUser object. Reference to user who wants to write message.
Folder Required. An ImapFolder object. Reference to folder that holds message.
Message Required. An ImapMessage object. Reference to message that is written to.
Action Required. An ImapActions enumeration, as described in settings. Return value you should fill with either Allow or Deny value, depending if you will allow user to write message or not.

Settings

The settings for Action are:

Constant Value Description
 Deny 0 Deny execution of the action.
 Allow 1 Allow to execute action.

Remarks
NOTE: This method is called only if you implemented IwodImapNotify interface in your application, and wodImapServer1.Notification property has received reference to instance of your implementation.

After user has created new message (CreateMessage was called when that happened), he may start writing to the message. All of this is most probably done automatically by his client software. Message contents are sent in chunks - and as each chunk is received this callback method is called to notify you that there's more data contained in Message.Body - and you should save it to your storage place. If you are saving messages to separate files, and you have already set Message.Filename - you can just ignore this callback method.