MprConfigTransportGetHandle

The MprConfigTransportGetHandle function retrieves a handle to the specified transport's configuration in the specified router configuration.

DWORD MprConfigTransportGetHandle(
  HANDLE hMprConfig,         // handle to the router configuration
  DWORD dwTransportId,       // transport identifier
  HANDLE *phRouterTransport  // handle to the transport's configuration
);

Parameters

hMprConfig
[in] Handle to the router configuration. The handle is obtained from a previous call to MprConfigServerConnect.
dwTransportId
[in] Specifies the transport for which to retrieve the configuration.
phRouterTransport
[out] Pointer to a handle variable. This variable receives a handle to the specified transport's configuration.

Return Values

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_INVALID_PARAMETER The hMprConfig parameter and/or the phRouterTransport parameter is NULL.
ERROR_NOT_ENOUGH_MEMORY Insufficient resources to complete the operation.
ERROR_UNKNOWN_PROTOCOL_ID The transport specified by dwTransportId was not found in the router configuration.
Other Use FormatMessage to retrieve the system error message that corresponds to the error code returned.

Requirements

  Windows NT/2000: Requires Windows 2000.
  Header: Declared in Mprapi.h.
  Library: Use Mprapi.lib.

See Also

Router Management Reference, Router Configuration Functions, FormatMessage, MprConfigServerConnect