protected void gridHangHoa_CustomErrorText(object sender, ASPxGridViewCustomErrorTextEventArgs e) { // if (e.Exception is CustomExceptions.MyException) // { // e.ErrorText = e.Exception.Message; // } }
protected override void OnCustomErrorText_BaseImplementation(ASPxGridViewCustomErrorTextEventArgs e) { if (e.Exception != null && e.Exception.InnerException != null) { e.ErrorText = e.Exception.InnerException.Message; } }
protected void grid_CustomErrorText(object sender, ASPxGridViewCustomErrorTextEventArgs e) { if (e.Exception.InnerException != null) { e.ErrorText += string.Format("{0}InnerException: '{1}'", Environment.NewLine, e.Exception.InnerException.Message); } }
protected void ASPxGridView1_CustomErrorText(object sender, ASPxGridViewCustomErrorTextEventArgs e) { if (e.Exception is MyException) { e.ErrorText = e.Exception.Message; } }
protected void ASPxGridView1_CustomErrorText(object sender, ASPxGridViewCustomErrorTextEventArgs e) { if (e.Exception.GetType() == typeof(NotSupportedException)) { e.ErrorText = "Online data modification is not supported. Download the example and implement your logic in the BatchUpdate event handler."; } }
protected void gv_CustomErrorText(object sender, ASPxGridViewCustomErrorTextEventArgs e) { if (e.Exception is CustomCallbackException) { e.ErrorText = e.Exception.Message; } }
protected void MUserInRolesGridView_CustomErrorText(object sender, ASPxGridViewCustomErrorTextEventArgs e) { e.ErrorText = e.Exception.Message; var lineNumber = new System.Diagnostics.StackTrace(e.Exception, true).GetFrame(0).GetFileLineNumber(); AppUtils.AddErrorLog(e.Exception.HResult, e.Exception.Source, $"{e.Exception.Message} - {e.Exception.StackTrace}", Context.User.Identity.GetUserName(), out errorLogId, lineNumber, -1, -1); }
protected void GvCuentaCorriente_CustomErrorText(object sender, ASPxGridViewCustomErrorTextEventArgs e) { //if (e.Exception is NullReferenceException) // e.ErrorText = e.Exception.Message; //else if (e.Exception is NotSupportedException) // e.ErrorText = e.Exception.Message; //else // e.ErrorText = "Ha ocurrido un error"; }
protected void gdvVendas_CustomErrorText(object sender, ASPxGridViewCustomErrorTextEventArgs e) { if (e.Exception.InnerException != null) { if (e.Exception.InnerException.Message.StartsWith("The DELETE statement conflicted with the REFERENCE constraint")) { e.ErrorText = "Não é possível excluir uma venda com produtos cadastrados."; } } }
protected void gdvClientes_CustomErrorText(object sender, ASPxGridViewCustomErrorTextEventArgs e) { if (e.Exception.InnerException != null) { if (e.Exception.InnerException.Message.StartsWith("The DELETE statement conflicted with the REFERENCE constraint")) { e.ErrorText = @"Não é possível excluir um cliente com saldo devedor na carteira."; } } }
protected void ASPxGridView1_CustomErrorText(object sender, ASPxGridViewCustomErrorTextEventArgs e) { if (e.Exception != null) { if (Session["errorMessage"] != null) { e.ErrorText = Utilidades.validarExepcionSQL(Session["errorMessage"].ToString()); Session["errorMessage"] = null; } } }
protected void ASPxgvTargets_CustomErrorText(object sender, ASPxGridViewCustomErrorTextEventArgs e) { if (e.Exception.InnerException.ToString().Contains("PRIMARY KEY")) { e.ErrorText = "You entered Duplicate Data, Please re-enter Unique information."; } else { e.ErrorText = e.Exception.ToString(); } }
protected override string RaiseCustomErrorText(ASPxGridViewCustomErrorTextEventArgs e) { var processingResult = ErrorHelper.Process(e.Exception); if (processingResult != null) { return(processingResult); } OnCustomErrorText_BaseImplementation(e); return(base.RaiseCustomErrorText(e)); }
protected void grid_CustomErrorText(object sender, ASPxGridViewCustomErrorTextEventArgs e) { if (e.Exception is NullReferenceException) { e.ErrorText = "NullReferenceExceptionText"; } else if (e.Exception is InvalidOperationException) { e.ErrorText = "InvalidOperationExceptionText"; } else if (e.Exception.Message.IndexOf("Cannot insert the value") != -1) { e.ErrorText = "Error al ingrear el REGISTRO, Seleccione 'Usuario' y 'Perfil' antes de GUARDAR... "; } }
/// <summary> /// catch insert error and replace with meaningful descriptions /// could also over ride this and throw exception on row_inserting event /// </summary> /// <param name="sender"></param> /// <param name="e"></param> protected void dxgrdTarget_CustomErrorText(object sender, ASPxGridViewCustomErrorTextEventArgs e) { if (e.Exception is NullReferenceException) { e.ErrorText = "Null Reference Exception" + e.Exception.Message.ToString(); } else if (e.Exception is InvalidOperationException) { e.ErrorText = "Invalid Operation Exception" + e.Exception.Message.ToString(); } else if (e.Exception is System.Reflection.TargetInvocationException && e.Exception.InnerException.ToString().Contains("duplicate key")) { e.ErrorText = "Not able to save record due to a duplicate company name"; } }
//8/21/2015 NS added for VSPLUS-2087 protected void ServersGridView_CustomErrorText(object sender, ASPxGridViewCustomErrorTextEventArgs e) { Exception ex = e.Exception; if (ex != null) { if (ex.Message.IndexOf("ErrCode!-1") != -1) { e.ErrorText = ex.Message; } else if (ex.Message.IndexOf("ErrCode=-1") > 0) { e.ErrorText = "some error"; } else { e.ErrorText = ex.Message; } } }
protected void UsersGridView_CustomErrorText(object sender, ASPxGridViewCustomErrorTextEventArgs e) { //6/9/2015 NS added for VSPLUS-1641 Exception ex = e.Exception; if (ex != null) { if (ex.Message.IndexOf("ErrCode!-1") != -1) { e.ErrorText = ex.Message; } else if (ex.Message.IndexOf("ErrCode=-1") > 0) { e.ErrorText = "some error"; } else { e.ErrorText = ex.Message; } } }
protected void gvPenerimaanProposal_CustomErrorText(object sender, ASPxGridViewCustomErrorTextEventArgs e) { String error = gvPenerimaanProposal.JSProperties["cpMessage"].ToString(); e.ErrorText = error; }
protected void gvAttachment_CustomErrorText(object sender, ASPxGridViewCustomErrorTextEventArgs e) { e.ErrorText = e.Exception.ToString(); }
protected override void OnCustomErrorText_BaseImplementation(ASPxGridViewCustomErrorTextEventArgs e) { if (e.Exception != null && e.Exception.InnerException != null) { e.ErrorText = e.Exception.InnerException.Message; } }
protected void grdInputCommLine_CustomErrorText(object sender, ASPxGridViewCustomErrorTextEventArgs e) { }
protected void gdvNiveis_CustomErrorText(object sender, ASPxGridViewCustomErrorTextEventArgs e) { if (e.Exception.Message.Contains("Duplicate")) { e.ErrorText = "Esta funcionalidade já foi configurada para este grupo."; } }
protected void gridView_CustomErrorText(object sender, ASPxGridViewCustomErrorTextEventArgs e) { }
protected void AttachmentGridview_CustomErrorText(object sender, ASPxGridViewCustomErrorTextEventArgs e) { e.ErrorText = e.Exception.InnerException.InnerException.Message; }
protected virtual void OnCustomErrorText_BaseImplementation(ASPxGridViewCustomErrorTextEventArgs e) { }
void gvPermohonan_CustomErrorText(object sender, ASPxGridViewCustomErrorTextEventArgs e) { e.ErrorText = e.Exception.GetBaseException().Message; }
protected virtual void OnCustomErrorText_BaseImplementation(ASPxGridViewCustomErrorTextEventArgs e) { }
protected override string RaiseCustomErrorText(ASPxGridViewCustomErrorTextEventArgs e) { var processingResult = ErrorHelper.Process(e.Exception); if (processingResult != null) return processingResult; OnCustomErrorText_BaseImplementation(e); return base.RaiseCustomErrorText(e); }
protected void ASPxGridView1_CustomErrorText(object sender, ASPxGridViewCustomErrorTextEventArgs e) { if(e.Exception != null){ if (Session["ErrorGenerado"] != null) { e.ErrorText = Session["ErrorGenerado"].ToString(); } } }
protected void gdvEstoque_CustomErrorText(object sender, ASPxGridViewCustomErrorTextEventArgs e) { if (e.Exception.InnerException != null) { e.ErrorText = e.Exception.InnerException.Message; } }
protected void ASPxGridView1_CustomErrorText(object sender, ASPxGridViewCustomErrorTextEventArgs e) { e.ErrorText = e.Exception.ToString(); }
protected void LAdministratorGridview_CustomErrorText(object sender, ASPxGridViewCustomErrorTextEventArgs e) { e.ErrorText = e.Exception.ToString(); }
/// <summary> /// catch insert error and replace with meaningful descriptions /// could also over ride this and throw exception on row_inserting event /// </summary> /// <param name="sender"></param> /// <param name="e"></param> protected void dxgrdTarget_CustomErrorText(object sender, ASPxGridViewCustomErrorTextEventArgs e) { if (e.Exception is NullReferenceException) { e.ErrorText = "Null Reference Exception" + e.Exception.Message.ToString(); } else if (e.Exception is InvalidOperationException) { e.ErrorText = "Invalid Operation Exception" + e.Exception.Message.ToString(); } else if (e.Exception is System.Reflection.TargetInvocationException && e.Exception.InnerException.ToString().Contains("duplicate key")) { e.ErrorText = "Not able to save record due to a duplicate company name"; } }