protected void ASPxGridView_AfterPerformCallback(object sender, ASPxGridViewAfterPerformCallbackEventArgs e) { if (e.CallbackName.Equals("APPLYCOLUMNFILTER") || e.CallbackName.Equals("SORT")) { ASPxGridView.JSProperties["cpJSONData"] = new JavaScriptSerializer().Serialize(GetBootstrapChartData()); } }
protected void gvCsmData_AfterPerformCallback(object sender, ASPxGridViewAfterPerformCallbackEventArgs e) { var sName = e.CallbackName; //try //{ // if (sName == "SELECTION") // { // sHTO = ((ASPxGridView)sender).GetRowValuesByKeyValue(sKey, "HTO").ToString(); // if (!string.IsNullOrEmpty(sHTO)) // { // Session["IsPerpHTO"] = sHTO; // GetSuspectHistory(); // } // } // else // { // if (sName == "FOCUSEDROW") // { // sHTO = ((ASPxGridView)sender).GetRowValuesByKeyValue(sKey, "HTO").ToString(); // } // } //} //catch (NullReferenceException ex) //{ // sMessage = String.Format("PT_DFAR.gvExclusions_AfterPerformCallback: Error performing callback... Error: {0}... SPECIFICS: {1}", ex.Message, ex.GetBaseException()); // SysDate = DateTime.Now; // //modProc.ProcErrLog("POI_Srch", int.Parse(Session["UserIdx"].ToString()), SysDate, sMessage, string.Empty, Session["RevLevel"].ToString()); //} }
protected void DetailGrid_AfterPerformCallback(object sender, ASPxGridViewAfterPerformCallbackEventArgs e) { ASPxGridView gv = (ASPxGridView)sender; gv.JSProperties.Add("cpIsCustomCallback", null); gv.JSProperties["cpIsCustomCallback"] = e.CallbackName == "CUSTOMCALLBACK"; }
protected void grid_AfterPerformCallback(object sender, ASPxGridViewAfterPerformCallbackEventArgs e) { if (!grid.Columns[1].Visible) { grid.Columns[0].Visible = (grid.FilterExpression != ""); } }
protected void ASPxgvAssessments_AfterPerformCallback(object sender, ASPxGridViewAfterPerformCallbackEventArgs e) { //if (e.CallbackName == "ADDNEWROW" || e.CallbackName == "STARTEDIT") // Session["PreviousCommand"] = e.CallbackName; //if (e.CallbackName == "UPDATEEDIT" && (string)Session["PreviousCommand"] == "STARTEDIT") // ASPxgvAssessments.StartEdit(ASPxgvAssessments.FocusedRowIndex); }
//end custom buttons protected void dxgridOrders_AfterPerformCallback(object sender, ASPxGridViewAfterPerformCallbackEventArgs e) { string _fx = this.dxgridOrders.FilterExpression.ToString(); if (!string.IsNullOrEmpty(_fx)) { this.dxgridOrders.SettingsText.Title = _fx; } }
protected void GridLookupPegawaiAset_AfterPerformCallback(object sender, ASPxGridViewAfterPerformCallbackEventArgs e) { GridLookupPegawaiAset.DataColumns["EmployeeName"].Settings.AutoFilterCondition = DevExpress.Web.AutoFilterCondition.Contains; GridLookupPegawaiAset.DataColumns["EmployeeId"].Settings.AutoFilterCondition = DevExpress.Web.AutoFilterCondition.Contains; GridLookupPegawaiAset.DataColumns["EmployeeDesignation"].Settings.AutoFilterCondition = DevExpress.Web.AutoFilterCondition.Contains; GridLookupPegawaiAset.DataColumns["EmployeePTJ"].Settings.AutoFilterCondition = DevExpress.Web.AutoFilterCondition.Contains; GridLookupPegawaiAset.DataColumns["StartDate"].Settings.AutoFilterCondition = DevExpress.Web.AutoFilterCondition.Equals; GridLookupPegawaiAset.DataColumns["EndDate"].Settings.AutoFilterCondition = DevExpress.Web.AutoFilterCondition.Equals; GridLookupPegawaiAset.DataColumns["ActiveStatus"].Settings.AutoFilterCondition = DevExpress.Web.AutoFilterCondition.Equals; }
protected void gv_AfterPerformCallback(object sender, ASPxGridViewAfterPerformCallbackEventArgs e) { if (e.CallbackName == "ADDNEWROW" || e.CallbackName == "STARTEDIT" || e.CallbackName == "CANCELEDIT") { foreach (string id in OpenedCanceledDocumentIDs) { DocumentManager.CloseDocument(id); } OpenedCanceledDocumentIDs.Clear(); } }
protected void base_AfterPerformCallback(object sender, ASPxGridViewAfterPerformCallbackEventArgs e) { ASPxGridView g = sender as ASPxGridView; if (e.CallbackName == "CUSTOMCALLBACK" && e.Args.Length == 1 && e.Args[0] == "UPDATEEDIT") { int rowIndex = g.EditingRowVisibleIndex; g.UpdateEdit(); ASPxWebControl.RedirectOnCallback("job_edit.aspx?id=" + txtSid.Text); //g.StartEdit(rowIndex); } }
protected void Grid_AfterPerformCallback(object sender, ASPxGridViewAfterPerformCallbackEventArgs e) { if (!CustomCallBack) { string QueryString = ddl.QueryString; object[] QueryParam = ddl.QueryParam; if (ddl.NeedFilter) { string strfilter = ""; for (int i = 1; i < Grid.Columns.Count; i++) { GridViewDataColumn ColumnId = (GridViewDataColumn)Grid.Columns[i]; if (ColumnId.FilterExpression != "") { if (ColumnId is GridViewDataDateColumn) { strfilter += " AND " + ColumnId.FilterExpression.Replace("#", "'"); } else { strfilter += " AND " + ColumnId.FilterExpression; } } } if (strfilter == "") { strfilter = " AND 1=0"; } if (QueryString.Trim().ToLower().IndexOf(" where ") == -1) { strfilter = " WHERE 1=1 " + strfilter; } QueryString = QueryString.ToUpper().Replace("SELECT ", "SELECT TOP 100 "); Grid.DataSource = ddl.conn.GetDataTable(QueryString + strfilter, QueryParam, ddl.DbTimeOut); Grid.DataBind(); } else { if (QueryString.ToLower().IndexOf("select") == 0) { dt = ddl.conn.GetDataTable(QueryString, QueryParam, ddl.DbTimeOut); } Grid.DataSource = dt; Grid.DataBind(); } Grid.JSProperties["cp_customcallback"] = "0"; } }
protected void gvProducts_AfterPerformCallback(object sender, ASPxGridViewAfterPerformCallbackEventArgs e) { ASPxGridView gridView = sender as ASPxGridView; string sessionField = String.Format("{0}_ColumnsOrder", gridView.ID); bool isColumnMoved = e.CallbackName == "COLUMNMOVE"; if (isColumnMoved) { Session[sessionField] = ColumnState.GetState(gridView.Columns); } gridView.JSProperties["cpIsColumnMoved"] = isColumnMoved; }
protected void OpsLiveGrid_AfterPerformCallback(object sender, ASPxGridViewAfterPerformCallbackEventArgs e) { //if (e.CallbackName == "APPLYCOLUMNFILTER") //{ // if (e.Args.ElementAt<string>(1) == "") //nothing typed there, so load default layout // { // LoadLayout(); // } // else //something typed there, so exapnd all groups // { // OpsLiveGrid.ExpandAll(); // } //} }
protected void grid_AfterPerformCallback(object sender, ASPxGridViewAfterPerformCallbackEventArgs e) { if (e.CallbackName == "COLUMNMOVE") { ASPxGridView gridView = (ASPxGridView)sender; if ((gridView.Columns[hf["fieldName"].ToString()]).Visible) { gridView.JSProperties["cpMoveTo"] = "Header"; } else { gridView.JSProperties["cpMoveTo"] = "Customization Window"; } } }
protected void gridHangHoa_AfterPerformCallback(object sender, ASPxGridViewAfterPerformCallbackEventArgs e) { int TrangThai = Convert.ToInt32(ccbLoaiHangHoa.Value.ToString()); if (TrangThai == 0) { gridHangHoa.SettingsCommandButton.DeleteButton.Image.IconID = "arrows_play_16x16"; gridHangHoa.SettingsCommandButton.DeleteButton.Image.ToolTip = "Ngừng kinh doanh"; } else { gridHangHoa.SettingsCommandButton.DeleteButton.Image.IconID = "arrows_pause_16x16"; gridHangHoa.SettingsCommandButton.DeleteButton.Image.ToolTip = "Đang kinh doanh"; } }
protected void grid_AfterPerformCallback(object sender, ASPxGridViewAfterPerformCallbackEventArgs e) { if (e.CallbackName == "COLUMNMOVE") { ASPxGridView gridView = (ASPxGridView)sender; gridView.JSProperties["cpColumnsInHeader"] = false; foreach (GridViewColumn column in gridView.Columns) { if (column.Visible && column.ShowInCustomizationForm) { gridView.JSProperties["cpColumnsInHeader"] = true; break; } } } }
protected void grvSTK_Machine_AfterPerformCallback(object sender, ASPxGridViewAfterPerformCallbackEventArgs e) { ASPxGridView editor = sender as ASPxGridView; try { switch (e.CallbackName) { case "APPLYFILTER": editor.PageIndex = 0; break; case "APPLYHEADERCOLUMNFILTER": editor.PageIndex = 0; break; case "CUSTOMCALLBACK": this.pageIndex = editor.PageIndex + 1; if (this.pageIndex >= editor.PageCount) //last page { this.pageIndex = 0; double minute = DateTime.Now.Subtract((DateTime)Session["LAST_UPDATE"]).TotalMinutes; double timediff = double.Parse(ConfigurationManager.AppSettings["TimeDiff"]); if (minute >= timediff) { this.GetStockByMachine(); } } editor.PageIndex = this.pageIndex; break; case "SORT": editor.PageIndex = 0; break; default: break; } } catch (Exception ex) { } }
//end custombutton callback /// <summary> /// fires after callback update title with filter description /// </summary> /// <param name="sender"></param> /// <param name="e"></param> protected void dxgridSearch_AfterPerformCallback(object sender, ASPxGridViewAfterPerformCallbackEventArgs e) { string _fx = this.dxgridSearch.FilterExpression.ToString(); if (!string.IsNullOrEmpty(_fx)) { this.dxgridSearch.SettingsText.Title = _fx; } //this.dxlblSearch.Text = _fx; } //yes, but how to use this to clear the grid of data //if callbackname = 'APPLYFILTER' and eventarg is empty string CLEAR button has been pressed //force grid to rebind with no filter as if page 1st load //string _cbn = e.CallbackName.ToString(); //string _arg = e.Args.Length > 0 ? e.Args[0].ToString() : ""; //if (_cbn == "APPLYFILTER" && _arg == "") //{ // Page.Session["SESSIONFILTER"] = "clear"; // //this.dxgridContainer.DataBind(); //} }
protected void GridEmpLookup_AfterPerformCallback(object sender, ASPxGridViewAfterPerformCallbackEventArgs e) { if (e.CallbackName == "CUSTOMCALLBACK") { if (GridLembagaPemeriksa.VisibleRowCount > 0) { DataTable Dt = new DataTable(); DataColumn LPD_EmpId = Dt.Columns.Add("LPD_EmpId", typeof(String)); Dt.AcceptChanges(); for (int i = 0; i < Dt.Rows.Count; i++) { for (int y = 0; y < GridEmpLookup.VisibleRowCount; y++) { if (GridEmpLookup.GetRowValues(y, "EmployeeId").ToString() == Dt.Rows[i]["LPD_EmpId"].ToString()) GridEmpLookup.Selection.SelectRow(y); } } } } }
protected void GridSearchAssetInv_AfterPerformCallback(object sender, ASPxGridViewAfterPerformCallbackEventArgs e) { if (e.CallbackName == "CUSTOMCALLBACK") { if (GridList.VisibleRowCount > 0) { DataTable Dt = new DataTable(); DataColumn PD_AssetInvUniqueId = Dt.Columns.Add("PD_AssetInvUniqueId", typeof(String)); Dt.AcceptChanges(); for (int i = 0; i < GridList.VisibleRowCount; i++) { DataRow Dr = Dt.NewRow(); Dr["PD_AssetInvUniqueId"] = GridList.GetRowValues(i, "TD_AssetInvUniqueId").ToString(); Dt.Rows.Add(Dr); } Dt.AcceptChanges(); string AssetInvUniqueId = string.Empty; for (int x = 0; x < Dt.Rows.Count; x++) { AssetInvUniqueId = Dt.Rows[x]["PD_AssetInvUniqueId"].ToString(); for (int y = 0; y < GridSearchAssetInv.VisibleRowCount; y++) { if (GridSearchAssetInv.GetRowValues(y, "AssInvUniqueId").ToString() == AssetInvUniqueId) { GridSearchAssetInv.Selection.SelectRow(y); } } } } else GridSearchAssetInv.Selection.UnselectAll(); } }
void PRI_TypeIdGridView_AfterPerformCallback(object sender, ASPxGridViewAfterPerformCallbackEventArgs e) { ASPxGridView PRI_TypeIdGridView = (ASPxGridView)sender; PRI_TypeIdGridView.DataColumns["T_Desc"].Settings.AutoFilterCondition = AutoFilterCondition.Contains; }
//end custombutton callback /// <summary> /// fires after callback update title with filter description /// </summary> /// <param name="sender"></param> /// <param name="e"></param> protected void dxgridSearch_AfterPerformCallback(object sender, ASPxGridViewAfterPerformCallbackEventArgs e) { string _fx = this.dxgridSearch.FilterExpression.ToString(); if (!string.IsNullOrEmpty(_fx)) { this.dxgridSearch.SettingsText.Title = _fx; }//this.dxlblSearch.Text = _fx; } //yes, but how to use this to clear the grid of data //if callbackname = 'APPLYFILTER' and eventarg is empty string CLEAR button has been pressed //force grid to rebind with no filter as if page 1st load //string _cbn = e.CallbackName.ToString(); //string _arg = e.Args.Length > 0 ? e.Args[0].ToString() : ""; //if (_cbn == "APPLYFILTER" && _arg == "") //{ // Page.Session["SESSIONFILTER"] = "clear"; // //this.dxgridContainer.DataBind(); //} }
protected void dxgridContact_AfterPerformCallback(object sender, ASPxGridViewAfterPerformCallbackEventArgs e) { Int32 _mode = Request.QueryString["cid"] != null ? wwi_func.vint(Request.QueryString["cid"].ToString()) : 0; bind_contacts(_mode); }
//end custom buttons protected void dxgridOrders_AfterPerformCallback(object sender, ASPxGridViewAfterPerformCallbackEventArgs e) { string _fx = this.dxgridOrders.FilterExpression.ToString(); if (!string.IsNullOrEmpty(_fx)) { this.dxgridOrders.SettingsText.Title = _fx; } }
protected void grid_AfterPerformCallback(object sender, ASPxGridViewAfterPerformCallbackEventArgs e) { DoBinding(); }
protected void gdvdln1_AfterPerformCallback(object sender, ASPxGridViewAfterPerformCallbackEventArgs e) { }
protected void GridSenaraiPelupusanHarta_AfterPerformCallback(object sender, ASPxGridViewAfterPerformCallbackEventArgs e) { }
protected void GridAssetInvPenempatan_AfterPerformCallback(object sender, ASPxGridViewAfterPerformCallbackEventArgs e) { GridAssetInvPenempatan.ExpandAll(); }
protected void dxgridTitles_AfterPerformCallback(object sender, ASPxGridViewAfterPerformCallbackEventArgs e) { bind_order_titles(); }
void PRI_ParentIdGridView_AfterPerformCallback(object sender, ASPxGridViewAfterPerformCallbackEventArgs e) { ASPxGridView PRI_ParentIdGridView = (ASPxGridView)sender; PRI_ParentIdGridView.DataBind(); }
/// <summary> /// rebind orders grid /// </summary> /// <param name="sender"></param> /// <param name="e"></param> protected void dxgrdContainerOrders_AfterPerformCallback(object sender, ASPxGridViewAfterPerformCallbackEventArgs e) { //attached orders grid binding int _id = wwi_func.vint(wwi_security.DecryptString(get_token("pid"), "publiship")); bind_orders_to_container(_id); }
protected void GridView_AfterPerformCallback(object sender, ASPxGridViewAfterPerformCallbackEventArgs e) { SynchronizeFocusedRow(); }
void PRI_SubCatIdGridView_AfterPerformCallback(object sender, ASPxGridViewAfterPerformCallbackEventArgs e) { ASPxGridView PRI_SubCatIdGridView = (ASPxGridView)sender; PRI_SubCatIdGridView.DataColumns["SubCatCode"].Settings.AutoFilterCondition = AutoFilterCondition.Contains; PRI_SubCatIdGridView.DataColumns["SubCatName"].Settings.AutoFilterCondition = AutoFilterCondition.Contains; }
protected void dxgridContact_AfterPerformCallback(object sender, ASPxGridViewAfterPerformCallbackEventArgs e) { Int32 _mode = Request.QueryString["cid"] != null?wwi_func.vint(Request.QueryString["cid"].ToString()) : 0; bind_contacts(_mode); }
protected void dxgridTitles_AfterPerformCallback(object sender, ASPxGridViewAfterPerformCallbackEventArgs e) { bind_order_titles(); }
protected void gridViewResearches_AfterPerformCallback(object sender, ASPxGridViewAfterPerformCallbackEventArgs e) { }
protected void DetailGrid_AfterPerformCallback(object sender, ASPxGridViewAfterPerformCallbackEventArgs e) { ASPxGridView gv = (ASPxGridView)sender; gv.JSProperties.Add("cpIsCustomCallback", null); gv.JSProperties["cpIsCustomCallback"] = e.CallbackName == "CUSTOMCALLBACK"; }
protected void grid_AfterPerformCallback(object sender, ASPxGridViewAfterPerformCallbackEventArgs e) { SendQuestionsAsEmail(); }