Export (0) Print
Expand All
1 out of 2 rated this helpful - Rate this topic

HttpRuntimeSection.MaxUrlLength Property

Gets or sets the maximum possible length, in number of characters, of the URL in an HTTP request.

Namespace:  System.Web.Configuration
Assembly:  System.Web (in System.Web.dll)
[<IntegerValidatorAttribute(MinValue = )>]
[<ConfigurationPropertyAttribute("maxUrlLength", DefaultValue = )>]
member MaxUrlLength : int with get, set

Property Value

Type: System.Int32
The length of the URL, in number of characters. The default is 260.

The value of the MaxUrlLength property can be any integer, zero or larger.

NoteNote

Extremely small values can make a Web site unusable.

If the length of the request URL (which is the value of the Path property) exceeds the configured size limit, ASP.NET returns an HTTP 400 (Bad Request) status code

You can set this value in a configuration file by setting the MaxUrlLength attribute of the httpRuntime element. For more information, see httpRuntime Element (ASP.NET Settings Schema).

.NET Framework

Supported in: 4

Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2

The .NET Framework does not support all versions of every platform. For a list of the supported versions, see .NET Framework System Requirements.
Did you find this helpful?
(1500 characters remaining)
Thank you for your feedback

Community Additions

ADD
Show:
© 2014 Microsoft. All rights reserved.