MprAdminSendUserMessage function (mprapi.h)

The MprAdminSendUserMessage function sends a message to the user connected on the specified connection.

Syntax

DWORD MprAdminSendUserMessage(
  [in] MPR_SERVER_HANDLE hMprServer,
  [in] HANDLE            hConnection,
  [in] LPWSTR            lpwszMessage
);

Parameters

[in] hMprServer

Handle to the RAS server on which the user is connected. Obtain this handle by calling MprAdminServerConnect.

[in] hConnection

Handle to the connection on which the user is connected. Use MprAdminConnectionEnum to obtain this handle.

[in] lpwszMessage

Pointer to a Unicode string that specifies the message to the user.

Return value

If the function succeeds, the return value is NO_ERROR.

If the function fails, the return value is one of the following error codes.

Value Meaning
ERROR_ACCESS_DENIED
The caller does not have sufficient privileges.
ERROR_DDM_NOT_RUNNING
The Demand Dial Manager (DDM) is not running, possibly because the Dynamic Interface Manager (DIM) is configured to run only on a LAN.
ERROR_INTERFACE_NOT_CONNECTED
The hConnection parameter is not valid.
ERROR_INVALID_PARAMETER
The lpwszMessage parameter is NULL.

Requirements

Requirement Value
Minimum supported client Windows 2000 Professional [desktop apps only]
Minimum supported server Windows 2000 Server [desktop apps only]
Target Platform Windows
Header mprapi.h
Library Mprapi.lib
DLL Mprapi.dll

See also

MprAdminConnectionEnum

RAS Administration Functions

Remote Access Service Administration Reference