RedirectResult Constructor

 

Initializes a new instance of the RedirectResult class.

Namespace:   System.Web.Mvc
Assembly:  System.Web.Mvc (in System.Web.Mvc.dll)

NameDescription
System_CAPS_pubmethodRedirectResult(String)

Initializes a new instance of the RedirectResult class.

System_CAPS_pubmethodRedirectResult(String, Boolean)

Initializes a new instance of the RedirectResult class using the specified URL and permanent-redirection flag.

Return to top

RedirectResult Constructor (String)

Initializes a new instance of the RedirectResult class.

public RedirectResult(
	string url
)

Parameters

url
Type: System.String

The target URL.

Exception Condition
ArgumentNullException

The url parameter is null.

Return to top

RedirectResult Constructor (String, Boolean)

Initializes a new instance of the RedirectResult class using the specified URL and permanent-redirection flag.

public RedirectResult(
	string url,
	bool permanent
)

Parameters

url
Type: System.String

The URL.

permanent
Type: System.Boolean

A value that indicates whether the redirection should be permanent.

Return to top
Show: