wodSmtpServer ActiveX Control - Connected Method
      
 

Description

Called when user successfully connects to Smtp server.


Return Type

None  


Syntax

object.Connected Owner, User, Action



The Connected Method syntax has these parts:

Part Description
object An expression evaluating to an object of type wodSmtpNotify.
Owner Required. A wodSmtpServer object. Reference to wodSmtpServerCom instance that called this callback method.
User Required. A SmtpUser object. Reference to the user who have connected.
Action Required. A SmtpActions enumeration, as described in settings.

You should set it to Allow or Deny to determine if login is successful.


Settings

The settings for Action are:

Constant Value Description
 Deny 0 Deny execution of the action.
 Allow 1 Allow to execute action.
 SilentDeny 2 Silently deny execution of the action.
 SilentAllow 3 Silently allow to execute action.

Remarks

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

Connected notification method is called so that application (or you) can prepare some internal buffers or code to receive message that is to be posted to the server. It's strictly informational. Unlike some other servers, SMTP server doesn't require Username/Password authentication, so there isn't such information provided here.

If you want, you can use Action variable to Deny access to the server, for instance based on IP filter of your own.