MprAdminInterfaceTransportAdd

The MprAdminInterfaceTransportAdd function adds a transport (for example, IP or IPX) to a specified interface.

DWORD MprAdminInterfaceTransportAdd(
  MPR_SERVER_HANDLE hMprServer,  // handle to the router
  HANDLE hInterface,             // handle to the interface
  DWORD dwTransportId,           // transport/router manager ID
  LPBYTE pInterfaceInfo,         // interface information
  DWORD dwInterfaceInfoSize      // size of interface information
);

Parameters

hMprServer
[in] Handle to the Windows 2000 router on which to execute this call. Obtain this handle by calling MprAdminServerConnect.
hInterface
[in] Handle to the interface on which to add the transport. This handle is obtained by a previous call to MprAdminInterfaceCreate.
dwTransportId
[in] Specifies the transport to add to the interface.
pInterfaceInfo
[in] Pointer to an information header that specifies interface information for this transport. Use the Information Header Functions to manipulate information headers.
dwInterfaceInfoSize
[in] Specifies the size, in bytes, of the information pointed to by pInterfaceInfo.

Remarks

The dwTransportId parameter also specifies the router manager because a Windows 2000 router uses a different router manager for each transport.

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_ACCESS_DENIED The calling application does not have sufficient privileges.
ERROR_INVALID_HANDLE The hInterface value is invalid.
ERROR_INVALID_PARAMETER The pInterfaceInfo parameter is NULL.
ERROR_UNKNOWN_PROTOCOL_ID The dwTransportId value does not match any installed transport.

Requirements

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

See Also

Router Management Reference, Router Administration Functions, MprAdminInterfaceCreate, MprAdminInterfaceTransportRemove, MprAdminServerConnect