.NET Framework Class Library
CustomErrorsSection..::.RedirectMode Property

Gets or sets a value that indicates whether the URL of the request should be changed when the user is redirected to a custom error page.

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

Visual Basic (Declaration)
<ConfigurationPropertyAttribute("redirectMode", DefaultValue := CustomErrorsRedirectMode.ResponseRedirect)> _
Public Property RedirectMode As CustomErrorsRedirectMode
Visual Basic (Usage)
Dim instance As CustomErrorsSection
Dim value As CustomErrorsRedirectMode

value = instance.RedirectMode

instance.RedirectMode = value
C#
[ConfigurationPropertyAttribute("redirectMode", DefaultValue = CustomErrorsRedirectMode.ResponseRedirect)]
public CustomErrorsRedirectMode RedirectMode { get; set; }
Visual C++
[ConfigurationPropertyAttribute(L"redirectMode", DefaultValue = CustomErrorsRedirectMode::ResponseRedirect)]
public:
property CustomErrorsRedirectMode RedirectMode {
    CustomErrorsRedirectMode get ();
    void set (CustomErrorsRedirectMode value);
}
JScript
public function get RedirectMode () : CustomErrorsRedirectMode
public function set RedirectMode (value : CustomErrorsRedirectMode)

Property Value

Type: System.Web.Configuration..::.CustomErrorsRedirectMode
A value that indicates whether the URL is changed when the user to the custom error page. The default value is ResponseRedirect.
Remarks

If the RedirectMode property is set to ResponseRedirect, the user is redirected to the error page and the original URL is changed to the URL of the error page. If the RedirectMode property is set to ResponseRewrite, the user is sent to error page and the original URL in the browser is not changed.

Platforms

Windows 7, Windows Vista, Windows XP SP2, Windows Server 2008 R2, Windows Server 2008, Windows Server 2003

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 SP1, 3.0 SP2, 2.0 SP2
See Also

Reference

Tags :


Page view tracker