-1

私のアプリケーションでは、エラー ページにリダイレクトしたいと考えています。エラーページにはユーザーフレンドリーなエラーを表示するラベルがあります。ページにリダイレクトできます。問題は、ユーザーフレンドリーなエラーにラベルを設定することです。

if (xy.Count() >= 1)
{            
    foreach (var x in xy)
    {
        employeeEmploy.Add(x);
        Debug.WriteLine(x.employee_personal_id);
    }
}
else 
{
    Security.ErrorControl.displayErrorMsg = "Employee Employ currently doesn't have any persons inside";

    Debug.WriteLine(Security.ErrorControl.displayErrorMsg); // class that set and get the error message i want to display

    HttpContext.Current.Response.Redirect("ssperror.aspx"); // I am getting to redirect .. just need to set the label to the error message.

}
4

1 に答える 1