コード例 #1
0
        protected void ScriptManager1_AsyncPostBackError(object sender, AsyncPostBackErrorEventArgs e)
        {
            string sError = String.Empty;

            if (e.Exception != null)
            {
                Exception objErr = e.Exception;
                sError = objErr.Message;
                if (objErr.StackTrace != null)
                {
                    sError += "\r\n<hr />\r\n" + objErr.StackTrace;
                }

                if (objErr.InnerException != null)
                {
                    sError += "\r\n<hr />\r\n" + objErr.InnerException;
                }

                SiteData.WriteDebugException("popup master - AsyncPostBackError", objErr);
            }
            else
            {
                sError = " An error occurred. (Generic Main) ";
            }

            ScriptManager1.AsyncPostBackErrorMessage = sError;
        }
コード例 #2
0
ファイル: BaseMPageMinus.cs プロジェクト: windygu/.net-wms
        void BaseMPageNew_AsyncPostBackError(object sender, AsyncPostBackErrorEventArgs e)
        {
            Exception ex          = e.Exception;
            string    errMsg      = string.Join("@", ex.Message.Split(Environment.NewLine.ToCharArray()));
            string    innerErrMsg = "";
            ArrayList errList     = new ArrayList();

            Exception innerEx = ex.InnerException;

            while (innerEx != null)
            {
                if (innerEx.Message != null)
                {
                    errList.Add(string.Join("@", innerEx.Message.Split(Environment.NewLine.ToCharArray())));
                }

                innerEx = innerEx.InnerException;
            }

            innerErrMsg = string.Join("@", (string[])errList.ToArray(typeof(string)));

            errMsg      = MessageCenter.ParserMessage(errMsg, this.languageComponent1).Replace("@", Environment.NewLine);
            innerErrMsg = FormatHelper.CleanString(MessageCenter.ParserMessage(innerErrMsg, this.languageComponent1)).Replace("@", Environment.NewLine);


            ScriptManager.GetCurrent(this.Page).AsyncPostBackErrorMessage = jsEncoder(errMsg) + "---" + jsEncoder(innerErrMsg);
        }
コード例 #3
0
ファイル: Default.aspx.cs プロジェクト: holmes2136/ShopCart
 protected void uxScriptManager_AsyncPostBackError(object sender, AsyncPostBackErrorEventArgs e)
 {
     uxScriptManager.AsyncPostBackErrorMessage =
         String.Format("Exception Type: {0}\n\nMessage: {1}\n\nMethod: {2}\n\nStack Trace:\n{3}",
                       e.Exception.GetType().ToString(),
                       e.Exception.Message,
                       e.Exception.TargetSite,
                       e.Exception.StackTrace);
 }
コード例 #4
0
        private static void sm_AsyncPostBackError(object sender, AsyncPostBackErrorEventArgs e)
        {
            ScriptManager sm = (ScriptManager)sender;

            if (e.Exception != null)
            {
                sm.AsyncPostBackErrorMessage = e.Exception.GetRealException().Message;
            }
        }
コード例 #5
0
    protected void ToolkitScriptManager1_AsyncPostBackError(object sender, AsyncPostBackErrorEventArgs e)
    {
        Exception E = e.Exception;

        Session["ExceptionFrom"]           = Request.Url;
        Session["ExceptionInnerException"] = E.InnerException;
        Session["ExceptionMessage"]        = E.Message;
        Session["ExceptionStackTrace"]     = E.StackTrace;
    }
コード例 #6
0
        /// <summary>
        /// Trata as exceções nas chamadas Ajax.
        /// </summary>
        /// <param name="sender">Objeto que está realizando o evento.</param>
        /// <param name="e">Contém os dados do evento.</param>
        protected void ScriptManager_AsyncPostBackError(object sender, AsyncPostBackErrorEventArgs e)
        {
            if (!e.Exception.Message.StartsWith("VALIDACAO:"))
            {
                // ExceptionHelper.LogException(e.Exception, this.Request.Path);
            }

            this.ScriptManager.AsyncPostBackErrorMessage = e.Exception.Message;
        }
コード例 #7
0
    protected void ScriptManager1_AsyncPostBackError(object sender, AsyncPostBackErrorEventArgs e)
    {
        if (e.Exception != null)
        {
            ScriptManager1.AsyncPostBackErrorMessage = e.Exception.Message;
            throw new Exception(e.Exception.Message + e.Exception.StackTrace);
        }

        //ScriptManager1.AsyncPostBackErrorMessage = e.Exception.Message;
    }
コード例 #8
0
 protected void manager_AsyncPostBackError(object sender, AsyncPostBackErrorEventArgs e)
 {
     if (e.Exception.Message != null)
     {
         this.manager.AsyncPostBackErrorMessage = e.Exception.Message;
     }
     else
     {
         this.manager.AsyncPostBackErrorMessage = "An unspecified error occurred.";
     }
 }
コード例 #9
0
ファイル: Site.Master.cs プロジェクト: xyAndroid/PhoneServer
 protected void ScriptManager1_AsyncPostBackError(object sender, AsyncPostBackErrorEventArgs e)
 {
     if (e.Exception.InnerException != null)
     {
         this.ScriptManager1.AsyncPostBackErrorMessage = e.Exception.InnerException.Message;
     }
     else
     {
         this.ScriptManager1.AsyncPostBackErrorMessage = e.Exception.Message;
     }
 }
コード例 #10
0
 protected void scriptManager_AsyncPostBackError(object sender, AsyncPostBackErrorEventArgs e)
 {
     if (e.Exception != null && e.Exception.InnerException != null)
     {
         scriptManager.AsyncPostBackErrorMessage = e.Exception.InnerException.Message;
         if (e.Exception.InnerException.InnerException != null)
         {
             scriptManager.AsyncPostBackErrorMessage = string.Concat(scriptManager.AsyncPostBackErrorMessage, " | (inner exception: ", e.Exception.InnerException.InnerException.Message, ")");
         }
     }
 }
コード例 #11
0
 protected void ScriptManager1_AsyncPostBackError(object sender, AsyncPostBackErrorEventArgs e)
 {
     if (this.Page is PageV4Base)
     {
         ((PageV4Base)this.Page).AsyncPostBackError(ScriptManager1, sender, e);
     }
     else
     {
         ScriptManager1.AsyncPostBackErrorMessage = "There was an error while doing a partial page update:\r\n" + e.Exception.ToString();
     }
 }
コード例 #12
0
        protected void ScriptManagerAsyncPostBackError(object sender, AsyncPostBackErrorEventArgs e)
        {
            string exceptionMessge = e.Exception.InnerException != null ? e.Exception.InnerException.Message : e.Exception.Message;
            string userMessage     = string.Empty;

            if (string.IsNullOrEmpty(userMessage))
            {
                userMessage = "Ha ocurrido un error mientras se realizaba la petición al servidor.";
            }

            scriptManager.AsyncPostBackErrorMessage = userMessage;
        }
コード例 #13
0
ファイル: LeafPage.Master.cs プロジェクト: odnodn/mscui
 /// <summary>
 /// Async postback error handler
 /// </summary>
 /// <param name="sender">Sender of the event.</param>
 /// <param name="e">Event Argument.</param>
 protected void DefaultScriptManager_AsynchronousPostBackError(object sender, AsyncPostBackErrorEventArgs e)
 {
     if (e.Exception.Data["ExtraInfo"] != null)
     {
         this.DefaultScriptManager.AsyncPostBackErrorMessage =
             e.Exception.Message +
             e.Exception.Data["ExtraInfo"].ToString();
     }
     else
     {
         this.DefaultScriptManager.AsyncPostBackErrorMessage =
             "An unspecified error occurred.";
     }
 }
コード例 #14
0
 protected void ScriptManager1_AsyncPostBackError(Object sender, AsyncPostBackErrorEventArgs e)
 {
     if (e.Exception.Data["GUID"] != null)
     {
         manager.AsyncPostBackErrorMessage = e.Exception.Message +
                                             " When reporting this error use the following ID: " +
                                             e.Exception.Data["GUID"].ToString();
     }
     else
     {
         manager.AsyncPostBackErrorMessage =
             "The server could not process the request.";
     }
 }
コード例 #15
0
ファイル: Base.master.cs プロジェクト: Farschidus/Ciemesus
 protected void CiemesusScriptManager_AsyncPostBackError(object sender, AsyncPostBackErrorEventArgs e)
 {
     if (e.Exception.Data["ExtraInfo"] != null)
     {
         CiemesusScriptManager.AsyncPostBackErrorMessage =
             e.Exception.Message +
             e.Exception.Data["ExtraInfo"].ToString();
     }
     else
     {
         CiemesusScriptManager.AsyncPostBackErrorMessage = e.Exception.Message + e.Exception.InnerException.Message +
                                                           "An unspecified error occurred.";
     }
 }
コード例 #16
0
 //to do
 protected void ScriptManagerMemberData_AsyncPostBackError(object sender, AsyncPostBackErrorEventArgs e)
 {
     //string errorMsg = "ScriptManager AsyncPostBackError. This may have been caused by a service call failure or the service may be down for maintenance. Please try again later. If you believe this is valid error please contact support. ";
     //ScriptManagerMemberData.AsyncPostBackErrorMessage = String.Format(GlobalMessages.sMSG_WARNING, e.Exception.Message + errorMsg);
     //    foreach (Control uc_Warning in GlobalUtils.EnumerateControlsRecursive(Page.Controls[0]))
     //    {
     //        if (uc_Warning.ID == "warningMessageControl")
     //        {
     //            usercontrol.uc_WarningMessage ms= ((usercontrol.uc_WarningMessage)uc_Warning);
     //            ms.ShowMessage("Test");
     //        }
     //        else if (uc_Warning.ID == "uc_MemberData1")
     //        {
     //            ((usercontrol.uc_MemberData)uc_Warning).FindControl("warningMessageControl").Visible = true;
     //        }
     //    }
 }
コード例 #17
0
        void _scriptManager_AsyncPostBackError(object sender, AsyncPostBackErrorEventArgs e)
        {
            var exception = e != null ? e.Exception : null;

            if (exception == null)
            {
                return;
            }

            var fullException = exception;

            var eKind = Sage.Platform.Diagnostics.ErrorHelper.GetTargetedException(fullException, out exception);

            var eMitigationType = Sage.Platform.Diagnostics.ErrorHelper.GetMitigationType(eKind, Request);

            var sSlxErrorId = Sage.Platform.Diagnostics.ErrorHelper.GetNewLoggingId();

            if (Sage.Platform.Diagnostics.ErrorHelper.ExceptionMustBeLogged(eKind))
            {
                Sage.Platform.Diagnostics.ErrorHelper.LogException(fullException, Request, log,
                                                                   string.Format(
                                                                       "{0} unhandled exception during async postback",
                                                                       Sage.Platform.Diagnostics.ErrorHelper.
                                                                       GetCurrentEventLogSource()), sSlxErrorId);
            }

            Server.ClearError();

            switch (eMitigationType)
            {
            case Sage.Platform.Diagnostics.ErrorHelper.MitigationType.AjaxLoginRedirect:
            case Sage.Platform.Diagnostics.ErrorHelper.MitigationType.LoginRedirect:
                FormsAuthSignOut();
                Response.Redirect("Login.aspx");
                break;

            default:
                _scriptManager.AsyncPostBackErrorMessage =
                    Sage.Platform.Diagnostics.ErrorHelper.GetErrorMessageContent(exception, Request, eKind,
                                                                                 sSlxErrorId, true, true,
                                                                                 Resources.SalesLogix.
                                                                                 MailDetailsLink);
                break;
            }
        }
コード例 #18
0
        protected void ucScriptManager_AsyncPostBackError(object sender, AsyncPostBackErrorEventArgs e)
        {
            string userName = "";
            string pageUrl  = "";

            //string app = UcConfParameters.UcAppName;

            if (page != null)
            {
                userName = page.UserName;
                pageUrl  = page.Request.Url.ToString();
            }

            Exception ex = new Exception("UCENTRIK Exception Code: " + "AJAX", e.Exception);

            UcSystem.HandleException(ex, userName, pageUrl);

            string errorPath = AppHelper.GetApplicationPath("~/dirApp/error.aspx?code=AJAX");

            Response.Redirect(errorPath);
        }
コード例 #19
0
 protected void ScriptManager1_AsyncPostBackError(object sender, AsyncPostBackErrorEventArgs e)
 {
     ScriptManager1.AsyncPostBackErrorMessage = e.Exception.Message;
     //Implement further error handling logic
 }
コード例 #20
0
 void ScriptManager_AsyncPostBackError(object sender, AsyncPostBackErrorEventArgs e)
 {
 }
コード例 #21
0
        /// <summary>
        /// Handles the AsyncPostBackError event of the PageScriptManager control.
        /// </summary>
        /// <param name="sender">The source of the event.</param>
        /// <param name="e">The <see cref="AsyncPostBackErrorEventArgs"/> instance containing the event data.</param>
        void PageScriptManager_AsyncPostBackError(object sender, AsyncPostBackErrorEventArgs e)
        {
            string message = e.Exception.Message;

            Master.PageScriptManager.AsyncPostBackErrorMessage = message;
        }
コード例 #22
0
 protected void GlobalScriptManager_AsyncPostBackError(object sender, AsyncPostBackErrorEventArgs e)
 {
     GlobalScriptManager.AsyncPostBackErrorMessage = ExceptionHandler.ThrowAJAXException(e.Exception);
 }
コード例 #23
0
 protected void ScriptManager1_AsyncPostBackError(object sender, AsyncPostBackErrorEventArgs e)
 {
     //在这里,可以指定自定义异常信息。
     ScriptManager1.AsyncPostBackErrorMessage = "异常信息为:" + e.Exception.Message;
 }
コード例 #24
0
 protected void OnAsyncPostBackError(object sender, AsyncPostBackErrorEventArgs e)
 {
     scmPeople.AsyncPostBackErrorMessage = e.Exception.Message;
 }
コード例 #25
0
 protected void ScriptManager1_AsyncPostBackError(object sender, AsyncPostBackErrorEventArgs e)
 {
     this.ScriptManager1.AsyncPostBackErrorMessage = "My error text";
 }
コード例 #26
0
 protected void ScriptManager1_AsyncPostBackError(object sender, AsyncPostBackErrorEventArgs e)
 {
     ScriptManager1.AsyncPostBackErrorMessage = e.Exception.Message;
 }
コード例 #27
0
ファイル: LogIn.aspx.cs プロジェクト: huaminglee/VSL_ERS
 protected void ScriptManager1_AsyncPostBackError(object sender, AsyncPostBackErrorEventArgs e)
 {
     SysLog.LogSystemError(e.Exception);
 }
コード例 #28
0
ファイル: Datum.Master.cs プロジェクト: fangliu520/Beeant
 protected void ScriptManager1_AsyncPostBackError(object sender, AsyncPostBackErrorEventArgs e)
 {
     Page.AddExceptionLog();
 }
コード例 #29
0
 // ReSharper disable once VirtualMemberNeverOverridden.Global
 protected virtual void ScriptManager_AsyncPostBackError(object sender,
                                                         AsyncPostBackErrorEventArgs e)
 {
     LogException("AsyncPostBackError", e.Exception);
 }
コード例 #30
0
 public void HandleError(object sender, AsyncPostBackErrorEventArgs e)
 {
     //ScrMng1.AsyncPostBackErrorMessage = "hata";
 }