System.Net.HttpWebRequest.SendChunked Property

Gets or sets a value that indicates whether to send data in segments to the Internet resource.

Syntax

public bool SendChunked { get; set; }

Value

true to send data in segments; otherwise, false. The default value is false.

Exceptions

TypeReason
InvalidOperationExceptionA set operation was requested but data has already been written to the request data stream.

Remarks

When HttpWebRequest.SendChunked is true, the request sends data to the Internet resource in segments. The Internet resource must support receiving chunked data.

Changing the HttpWebRequest.SendChunked property after the request has been started by calling the HttpWebRequest.GetRequestStream, HttpWebRequest.BeginGetRequestStream(AsyncCallback, object), HttpWebRequest.GetResponse, or HttpWebRequest.BeginGetResponse(AsyncCallback, object) method throws an InvalidOperationException.

Requirements

Namespace: System.Net
Assembly: System (in System.dll)
Assembly Versions: 1.0.5000.0, 2.0.0.0, 4.0.0.0