DirectX SDK

DirectPlay4.SetGroupName

The DirectPlay4.SetGroupName method sets the name of a group after it has been created. Only the computer that created the group can set the name of the group.

object.SetGroupName(GroupId As Long, _
    friendlyName As String, _
    formalName As String, _
    flags As CONST_DPSETFLAGS) 

Parameters

object
Object expression that resolves to a DirectPlay4 object.
GroupId
ID of the group for which the name is being set.
friendlyName
Short name of the group. Set this parameter to "" if the group has no friendly name.
formalName
Long name of the group. Set this parameter to "" if the group has no formal name.
flags
Flag from the CONST_DPSETFLAGS enumeration that sets the data propagation options. If this parameter is set to 0, the name will be propagated to all the remote systems by using nonguaranteed message passing.

Error Codes

If the method fails, an error is raised and Err.Number may be set to one of the following values:

DPERR_CONNECTIONLOST
DPERR_INVALIDGROUP
DPERR_INVALIDOBJECT
DPERR_INVALIDPARAMS
DPERR_INVALIDPLAYER

Remarks

A DPSYS_SETPLAYERORGROUPNAME system message will be sent to all the other players notifying them of the change unless DPSESSION_NODATAMESSAGES is set in the session description.

See Also

DirectPlay4.GetGroupLongName, DirectPlay4.GetGroupShortName, DirectPlay4.Send