cmc_logoff
The cmc_logoff function logs a client application off a message service.
Quick Info
CMC_return_code cmc_logoff (
CMC_session_id session,
CMC_ui_id ui_id,
CMC_flags logoff_flags,
CMC_extension FAR * logoff_extensions
)
Parameters
-
session
-
[in] Opaque session handle that represents a MAPI session object indicating a session with a message service. If the session handle is invalid, the cmc_logoff function returns cmc_e_invalid_session_id. After cmc_logoff returns, the session handle is invalid.
-
ui_id
-
[in] Handle of a dialog box for cmc_logoff to present to help resolve processing questions.
-
logoff_flags
-
[in] Bitmask of flags. The following flags can be set:
-
CMC_ERROR_UI_ALLOWED
-
Displays a dialog box on encountering recoverable errors. If this flag is not set, cmc_logoff does not display a dialog box and returns an error value instead.
-
CMC_LOGOFF_UI_ALLOWED
-
Indicates cmc_logoff can display a dialog box for other purposes than displaying error messages while logging the user off from the session.
-
logoff_extensions
-
[in, out] Pointer to an array of CMC_extension structures containing function extensions. On input, this array contains MAPI extensions to the standard cmc_logoff function. A value of NULL for the logoff_extensions parameter indicates that the client application has no extensions for cmc_logoff and is expecting no extensions.
On output, cmc_logoff writes to the array new information about the logoff operation. It writes NULL if it generates no output extensions.
Return Values
-
CMC_E_FAILURE
-
There was a general failure that does not fit the description of any other return value.
-
CMC_E_INSUFFICIENT_MEMORY
-
Insufficient memory was available to complete the requested operation.
-
CMC_E_INVALID_FLAG
-
A flag set using a flags parameter was invalid.
-
CMC_E_INVALID_PARAMETER
-
A function parameter was invalid.
-
CMC_E_INVALID_SESSION_ID
-
The specified session handle is invalid or no longer valid — for example, after logging off.
-
CMC_E_INVALID_UI_ID
-
The specified user-interface identifier is invalid or no longer valid.
-
CMC_E_UNSUPPORTED_FLAG
-
The flag requested is not supported.
-
CMC_E_UNSUPPORTED_FUNCTION_EXT
-
The function extension requested is not supported.
-
CMC_E_USER_NOT_LOGGED_ON
-
The user was not logged on and the CMC_LOGON_UI_ALLOWED flag was not set.
See Also
CMC_extension