.NET Framework Class Library
HttpRuntimeSection..::.RequestLengthDiskThreshold Property

Gets or sets the input-stream buffering threshold.

Namespace:  System.Web.Configuration
Assembly:  System.Web (in System.Web.dll)
Syntax

Visual Basic (Declaration)
<ConfigurationPropertyAttribute("requestLengthDiskThreshold", DefaultValue := )> _
<IntegerValidatorAttribute(MinValue := )> _
Public Property RequestLengthDiskThreshold As Integer
Visual Basic (Usage)
Dim instance As HttpRuntimeSection
Dim value As Integer

value = instance.RequestLengthDiskThreshold

instance.RequestLengthDiskThreshold = value
C#
[ConfigurationPropertyAttribute("requestLengthDiskThreshold", DefaultValue = )]
[IntegerValidatorAttribute(MinValue = )]
public int RequestLengthDiskThreshold { get; set; }
Visual C++
[ConfigurationPropertyAttribute(L"requestLengthDiskThreshold", DefaultValue = )]
[IntegerValidatorAttribute(MinValue = )]
public:
property int RequestLengthDiskThreshold {
    int get ();
    void set (int value);
}
JScript
public function get RequestLengthDiskThreshold () : int
public function set RequestLengthDiskThreshold (value : int)

Property Value

Type: System..::.Int32
The number of bytes that indicate the input-stream buffering threshold. The default is 256 bytes.
Exceptions

ExceptionCondition
ConfigurationErrorsException

The selected value is greater than MaxRequestLength.

Remarks

The RequestLengthDiskThreshold property specifies the input-stream buffering threshold limit in number of bytes. Its value should not exceed the MaxRequestLength property value. After a request entity exceeds this threshold, it is buffered transparently onto disk.

Examples

The following example shows how to use the RequestLengthDiskThreshold property.

Visual Basic
' Get the RequestLengthDiskThreshold property value.
Response.Write("RequestLengthDiskThreshold: " & _
  configSection.RequestLengthDiskThreshold & "<br>")

' Set the RequestLengthDiskThreshold property value to 512 bytes.
configSection.RequestLengthDiskThreshold = 512
C#
// Get the RequestLengthDiskThreshold property value.
Response.Write("RequestLengthDiskThreshold: " +
  configSection.RequestLengthDiskThreshold + "<br>");

// Set the RequestLengthDiskThreshold property value to 512 bytes.
configSection.RequestLengthDiskThreshold = 512;
Platforms

Windows 7, Windows Vista, Windows XP SP2, Windows XP Media Center Edition, Windows XP Professional x64 Edition, Windows XP Starter Edition, Windows Server 2008 R2, Windows Server 2008, Windows Server 2003, Windows Server 2000 SP4, Windows Millennium Edition, Windows 98

The .NET Framework and .NET Compact Framework do not support all versions of every platform. For a list of the supported versions, see .NET Framework System Requirements.
Version Information

.NET Framework

Supported in: 3.5, 3.0, 2.0
See Also

Reference

Other Resources

Tags :


Community Content

AbdElRaheim
requestLengthDiskThreshold
Is the documentation for requestLengthDiskThreshold correct? I read in other places that the actually default size is 80KB and the parameter is specified in kilobytes not bytes.
Tags : contentbug

Page view tracker