AdoConnectionEvents:WillConnect()

<< Click to Display Table of Contents >>

Navigation:  Ado Events > AdoConnectionEvents Class >

AdoConnectionEvents:WillConnect()

Previous pageReturn to chapter overviewNext page

Note

Please note that event handling is not supported in the current version of Xs2Ado

Purpose

The WillConnect event is called before a connection starts

 

Prototype

METHOD WillConnect ( cConnStr, cUser, cPassword, lOptions, lStatus, oConn) CLASS AdoConnectionEvents

 

Argument(s)

cConnStr        A String that contains connection information for the pending connection

cUser        A String that contains connection information for the pending connection

cPassword        A String that contains the password for the pending connection

lOptions        A Long value that indicates how the provider should evaluate the ConnectionString. Your only option is adAsyncOpen

lStatus        An AdoEventStatusEnum status value. This parameter is set to adStatusOK if the operation that caused the event was successful, or to adStatusCantDeny if this event cannot request cancellation of the pending operation

oConn        The Connection object for which this event notification applies.

 

 

Description

When WillConnect is called, the ConnectionString, UserID, Password, and Options parameters are set to the values established by the operation that caused this event (the pending connection), and can be changed before the event returns. WillConnect may return a request that the pending connection be canceled.

 

See Also

AdoConnectionEvents, AdoEventStatusEnum, AdoConnection:Open