RtmInsertInRouteList function (rtmv2.h)

The RtmInsertInRouteList function inserts the specified set of routes into the client's route list. If a route is already in another list, the route is removed from the old list and inserted into the new one.

Syntax

DWORD RtmInsertInRouteList(
  [in] RTM_ENTITY_HANDLE     RtmRegHandle,
  [in] RTM_ROUTE_LIST_HANDLE RouteListHandle,
  [in] UINT                  NumRoutes,
  [in] PRTM_ROUTE_HANDLE     RouteHandles
);

Parameters

[in] RtmRegHandle

Handle to the client obtained from a previous call to RtmRegisterEntity.

[in] RouteListHandle

Handle to the route list to which to add routes. Specify NULL to remove the specified routes from their old lists.

[in] NumRoutes

Specifies the number of routes in RouteHandles.

[in] RouteHandles

Pointer to an array of route handles to move from the old list to the new list.

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_INVALID_HANDLE
The handle is invalid.

Remarks

When the routes are no longer required, release them by calling RtmReleaseRoutes.

For sample code using this function, see Use a Client-Specific Route List.

Requirements

Requirement Value
Minimum supported client None supported
Minimum supported server Windows 2000 Server [desktop apps only]
Target Platform Windows
Header rtmv2.h
Library Rtm.lib
DLL Rtm.dll

See also

RtmCreateRouteList

RtmDeleteRouteList