IMsgrSession::SendContextData method

[SendContextData is no longer available for use as of Windows Vista. See Windows Messenger for more information.]

Sends application-specific context data.

Syntax

HRESULT SendContextData(
  [in] BSTR bstrData
);

Parameters

bstrData [in]

Type: BSTR

BSTR specifying context data for the application. bstrData has a limit of 300 characters.

Return value

Type: HRESULT

Returns one of the following values.

Return code Description
S_OK
The application-specific context data was sent successfully.
E_INVALIDARG
The application-specific context data passed to the method was not valid.
SR_CONTEXT_DATA_OVER_LIMIT
The amount of context data is too large to be sent.
SR_NOT_VALID_FOR_APP_INVITE
The context data is not valid for an invitation.
E_OUTOFMEMORY
There is not enough memory available to send the context data.

Remarks

SendContextData should only be used by applications connecting to exchange information required to establish a peer-to-peer connection. This method can be called up to five times after the applications have established their own communication.

The following table lists the error codes returned by this method.

Error Code Meaning
0x8007000E There is not enough memory available to send the context data.
0x80070057 The application-specific context data passed to the method was not valid.
SR_NOT_VALID_FOR_APP_INVITE (0x8100060f) The context data is not valid for an invitation.
SR_CONTEXT_DATA_OVER_LIMIT (0x81000611) The amount of context data is too large to be sent.

Requirements

Minimum supported client
Windows XP [desktop apps only]
Minimum supported server
Windows Server 2003 [desktop apps only]
End of client support
Windows XP
End of server support
Windows Server 2003
Product
Messenger 4.0
Header
Msgrpriv.h
IDL
Msgrpriv.idl
DLL
Msgsc.dll

See also

IMsgrSession

Messenger Session Invite and Messenger Private APIs

Messenger Lock and Key API