DirectPlay Animated Header -- IDirectPlay3::DestroyGroup DirectPlay Animated Header -- IDirectPlay3::DestroyGroup* Microsoft DirectPlay SDK
*Index  *Topic Contents
*Previous Topic: IDirectPlay3::DeletePlayerFromGroup
*Next Topic: IDirectPlay3::DestroyPlayer


IDirectPlay3::DestroyGroup


IDirectPlay3 Interface

Deletes a group from the session. The ID belonging to this group will not be reused during the current session.

HRESULT DestroyGroup(
  DPID idGroup
  );

Parameters
idGroup
The ID of the group being removed from the game.
Return Values

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

DPERR_INVALIDGROUP
DPERR_INVALIDOBJECT
DPERR_INVALIDPARAMS
DPERR_INVALIDPLAYER
Remarks

It is not necessary to empty a group before deleting it. The individual players belonging to the group are not destroyed. This method will generate a DPMSG_DELETEPLAYERFROMGROUP system message for each player in the group, and then a DPMSG_DESTROYPLAYERORGROUP system message. For a list of system messages, see Using System Messages.

Any application can destroy any group even if the group was not created locally.

See Also

IDirectPlay3::CreateGroup, DPMSG_DESTROYPLAYERORGROUP

© 1998 Microsoft Corporation. All rights reserved. Terms of Use.

*Top of Page