Adds an HTTP request header to the HTTP request message used in the WebSocket protocol handshake by the StreamWebSocket object.
public:
void SetRequestHeader(
String^ headerName,
String^ headerValue
)
headerName
Type: String
The name of the request header.
headerValue
Type: String
The value of the request header.
The SetRequestHeader method must be called prior to calling the ConnectAsync method. Calling the SetRequestHeader method after calling the ConnectAsync method will result in an error.
Namespace: Windows.Networking.Sockets
Metadata: windows.winmd