Esempio n. 1
0
        protected void Application_Error(object sender, EventArgs e)
        {
            Exception exception = Server.GetLastError();

            if (exception != null)
            {
                if (exception.GetType() == typeof(ArgumentException))
                {
                    logManager.AddExcaptionLog(exception.Message);
                    Response.Redirect("/ErrorHandler/Error404");
                }
                else
                {
                    logManager.AddExcaptionLog(exception.Message);
                    Response.Redirect("/ErrorHandler/Error");
                }
            }
        }