Platform SDK: DirectX

IDirectPlay4::AddGroupToGroup

The IDirectPlay4::AddGroupToGroup method adds a shortcut to a group to an already existing group. This allows the linked group to be enumerated by the IDirectPlay4::EnumGroupsInGroup method. To remove a group's shortcut from another group, call DeleteGroupFromGroup.

HRESULT AddGroupToGroup(
  DPID idParentGroup,
  DPID idGroup
);

Parameters

idParentGroup
ID of the group to which the shortcut will be added. Can be any valid group ID.
idGroup
The group ID of the group whose shortcut will be added. Can be any valid group ID.

Return Values

Returns DP_OK if successful, or one of the following error values otherwise:

DPERR_ACCESSDENIED
DPERR_CONNECTIONLOST
DPERR_INVALIDGROUP

Remarks

This method can be used to place a group "inside" more than one group.

A DPMSG_ADDGROUPTOGROUP system message is generated to inform players of this change.

Requirements

  Windows NT/2000: Requires Windows 2000.
  Windows 95/98: Requires Windows 95 or later. Available as a redistributable for Windows 95.
  Header: Declared in dplay.h.
  Import Library: Use dplayx.lib.

See Also

IDirectPlay4::CreateGroupInGroup, IDirectPlay4::DeleteGroupFromGroup, IDirectPlay4::EnumGroupsInGroup, DPMSG_ADDGROUPTOGROUP