Platform SDK: DirectX

DirectPlayLobby3.SendLobbyMessage

The DirectPlayLobby3.SendLobbyMessage method sends a message between the application and the lobby client.

object.SendLobbyMessage(flags As CONST_DPLMSG, _
    applicationId As Long, _
    msg As DirectPlayMessage) 

Parameters

object
Object expression that resolves to a DirectPlayLobby3 object.
flags
Flags from the CONST_DPLMSG enumeration indicating the type of message being sent. The default (flags = 0 or DPLMSG_USERDEFINED) is a custom message defined by the application sending it. Another possible value is DPLMSG_STANDARD—this is a standard message defined by DirectPlay.
applicationId
Identifies which application to send a message to when called from a lobby client (that communicates with several applications). When called from an application (that communicates with only one lobby client), this parameter must be 0. This ID is obtained by using the DirectPlayLobby3.RunApplication method.
msg
DirectPlayMessage object representing the message to be sent. This object is obtained by using the DirectPlayLobby3.CreateMessage method.

Error Codes

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

DPERR_APPNOTSTARTED
DPERR_BUFFERTOOLARGE
DPERR_GENERIC
DPERR_INVALIDINTERFACE
DPERR_INVALIDOBJECT
DPERR_INVALIDPARAMS
DPERR_OUTOFMEMORY
DPERR_TIMEOUT

See Also

DirectPlayLobby3.ReceiveLobbyMessage