Adds a HTTP Range header to the current instance for a specific range from the beginning or end of the requested data.
- range
- A int that specifies the starting or ending point of the range. If this value is positive, the range is from the beginning of the data to range. If this value is negative, the range is from range to the end of the data.
Type Reason InvalidOperationException The range header could not be added.
This method is equivalent to HttpWebRequest.AddRange(int, int)("bytes", range).
Note:The HTTP Range header specifies either a single range of bytes or a set of byte ranges in an entity-body to be returned. If the server accessed by the current instance supports the use of this header, this allows for the partial retrieval of the entity due to, for example, the entity being particularly large or there having been a failed transfer of data.
For more information on the HTTP Range header, see Section 14.35 of RFC 2616.
Namespace: System.Net
Assembly: System (in System.dll)
Assembly Versions: 1.0.5000.0, 2.0.0.0