Sets the body of the HTTP request that will be sent to the server.
This method is normally used with a POST or PUT request.
Namespace: Facilita.WebAssembly: clrWebBrowser (in clrWebBrowser.dll) Version: 9.5.7.98 (1.0.0.0)
Syntax
Parameters
- messageBody
- Type: System Byte
The body of the message (e.g. the POST data).
Remarks
- If the message body is a Form, then you should use the SetMessageBody(Form) overload instead.
- If the message body consists of text, then you should use the SetMessageBody(String) overload.
- If the message body is very large, then it may be easier to store the data in a file and use the SetMessageBodyFromFile(String) method instead.
Examples
Url url32 = new Url(protocol1, localhost, "/login"); Request request32 = Browser.CreateRequest(HttpMethod.POST, url32, 32); request32.SetMessageBody(new byte[] { 0x01, 0x02, 0x03}); Response response32 = request32.Send();
See Also