IWRdsProtocolConnection::LogonNotify method (wtsprotocol.h)

Called when the user has logged on to the session.

Syntax

HRESULT LogonNotify(
  [in]      HANDLE_PTR                hClientToken,
  [in]      WCHAR                     *wszUserName,
  [in]      WCHAR                     *wszDomainName,
  [in]      WRDS_SESSION_ID           *SessionId,
  [in, out] PWRDS_CONNECTION_SETTINGS pWRdsConnectionSettings
);

Parameters

[in] hClientToken

A handle that represents the user token.

[in] wszUserName

A pointer to a null-terminated string that contains the user name.

[in] wszDomainName

A pointer to a null-terminated string that contains the user's domain name.

[in] SessionId

A pointer to a WRDS_SESSION_ID structure that uniquely identifies the session.

[in, out] pWRdsConnectionSettings

A pointer to a WRDS_CONNECTION_SETTINGS structure that contains connection settings for the session.

Return value

If this method succeeds, it returns S_OK. Otherwise, it returns an HRESULT error code.

Remarks

This is an event notification and you should return immediately from this method. To avoid a possible deadlock, you should not make any function or method calls that will directly or indirectly result in a Remote Desktop Services API being called. If you need to make any outbound call, you should start a new thread and make the outbound call from the new thread.

Requirements

Requirement Value
Minimum supported client None supported
Minimum supported server Windows Server 2012
Target Platform Windows
Header wtsprotocol.h

See also

IWRdsProtocolConnection