IDirectPlayLobby3::GetConnectionSettings
IDirectPlayLobby3 InterfaceRetrieves the DPLCONNECTION structure that contains all the information needed to start and connect an application. The data returned is the same data that was passed to the IDirectPlayLobby3::RunApplication method by the lobby client, or set by calling the IDirectPlayLobby3::SetConnectionSettings method.
Syntax
HRESULT GetConnectionSettings(
DWORD dwAppID,
LPVOID lpData,
LPDWORD lpdwDataSize
);Parameters
- dwAppID
- Identifies which application's connection settings to retrieve when called from a lobby client (that communicates with several applications). When called from an application (that only communicates with one lobby client), this parameter must be zero. This ID number is obtained from IDirectPlayLobby3::RunApplication.
- lpData
- Pointer to a buffer in which the connection settings are to be written. Set this parameter to NULL to request only the size of data. The lpdwDataSize parameter will be set to the minimum size required to hold the data.
- lpdwDataSize
- Pointer to a variable that is initialized to the size of the buffer before calling this method. After the method returns, this parameter will be set to the size, in bytes, of the data. If the buffer was too small (DPERR_BUFFERTOOSMALL), then this parameter will be set to the minimum buffer size required.
Return Value
Returns DP_OK if successful, or one of the following error values otherwise:
DPERR_BUFFERTOOSMALL DPERR_GENERIC DPERR_INVALIDINTERFACE DPERR_INVALIDOBJECT DPERR_INVALIDPARAMS DPERR_NOTLOBBIED DPERR_OUTOFMEMORY Remarks
The lpData member should be cast to the DPLCONNECTION structure when the function returns to read the data from it.
See Also
DPLCONNECTION, IDirectPlayLobby3::RunApplication, IDirectPlayLobby3::SetConnectionSettings, IDirectPlayLobby3::WaitForConnectionSettings
Top of Page
© 1998 Microsoft Corporation. All rights reserved. Terms of Use.