IDirectPlayLobby::CreateAddress
HRESULT CreateAddress(REFGUID guidSP,
REFGUID guidDataType, LPCVOID lpData,
DWORD dwDataSize, LPVOID lpAddress,
LPDWORD lpdwAddressSize);
Creates a DirectPlay Address, given a service provider-specific network address. The resulting address contains the globally unique identifier (GUID) of the service provider and data that the service provider can interpret as a network address.
·Returns DP_OK if successful, or one of the following error values otherwise:
guidSP
Address of the GUID of the service provider. (In C++, it is a reference to the GUID.)
guidDataType
Address of a GUID identifying the specific network address type being used. For information about predefined network address types, see DirectPlay Address. (In C++, it is a reference to the GUID.)
lpData
Address of a buffer containing the specific network address.
dwDataSize
Size, in bytes, of the network address in lpData.
lpAddress
Address of a buffer in which the constructed DirectPlay Address is to be written.
lpdwAddressSize
Address of a variable containing the size of the DirectPlay Address buffer. Before calling this method, the service provider must initialize lpdwAddressSize to the size of the buffer. After the method has returned, this parameter will contain the number of bytes written to lpAddress. If the buffer was too small (DPERR_BUFFERTOOSMALL), this parameter will be set to the size required to store the DirectPlay Address.