The Visual Basic MAPILogoff function ends a session with the messaging system.
Quick Info
Header file:
MAPIVB32.BAS
MAPILogoff(
Session as Long, UIParam as Long, Flags as Long, Reserved as Long) as Long
Parameters
Session
[in] Handle for a Simple MAPI session to be terminated. Session handles are returned by MAPILogon and invalidated by MAPILogoff. The value of the Session parameter must represent a valid session; it cannot be zero.
UIParam
[in] Parent window handle or zero, indicating that if a dialog box is displayed, it is application modal. If no dialog box is displayed during the call, the UIParam parameter is ignored.
Flags
Reserved; must be zero.
Reserved
Reserved; must be zero.
Return Values
MAPI_E_FAILURE
One or more unspecified errors occurred.
MAPI_E_INSUFFICIENT_MEMORY
There was insufficient memory to proceed. The session was not terminated.
MAPI_E_INVALID_SESSION
An invalid session handle was used for the Session parameter. The session was not terminated.
SUCCESS_SUCCESS
The call succeeded and the session was terminated.
The declaration of this function for the 32-bit Visual Basic runtime is:
MAPILogoff(
ByVal Session&,
ByVal UIParam&,
ByVal Flags&,
ByVal Reserved&) As Long