CustomError.Redirect プロパティ

定義

リダイレクト URL を取得または設定します。

public:
 property System::String ^ Redirect { System::String ^ get(); void set(System::String ^ value); };
[System.Configuration.ConfigurationProperty("redirect", IsRequired=true)]
[System.Configuration.StringValidator(MinLength=1)]
public string Redirect { get; set; }
[<System.Configuration.ConfigurationProperty("redirect", IsRequired=true)>]
[<System.Configuration.StringValidator(MinLength=1)>]
member this.Redirect : string with get, set
Public Property Redirect As String

プロパティ値

エラー発生時にアプリケーションがリダイレクトされる URL。

属性

次のコード例は、リダイレクト URL の使用方法を示しています。 コレクションを取得する方法については、クラス トピックの CustomError コード例を参照してください。

// Get first errorr Redirect.
CustomError currentError0 =
    customErrorsCollection[0];
string currentRedirect =
    currentError0.Redirect;

// Set first error Redirect.
currentError0.Redirect =
    "customError404.htm";
' Get first errorr Redirect.
  Dim currentError0 As CustomError = _
  customErrorsCollection(0)
  Dim currentRedirect As String = _
  currentError0.Redirect

' Set first error Redirect.
currentError0.Redirect = "customError404.htm"

注釈

プロパティは Redirect 、特定のエラーに関連付けられているカスタム ページの URL を識別します。

適用対象