private void RegisterGridCellDataChangedPostBack()
{
AssociationControl assocControl = new AssociationControl();
assocControl.SourceServerControl = this.DataGrid8;
assocControl.SourceControl.EventName = "OnCellDataValueChanged";
//针对数量和价格这两个列的变化
((IUFClientAssoGrid)assocControl.SourceControl).FireEventCols.Add("ItemQty");
((IUFClientAssoGrid)assocControl.SourceControl).FireEventCols.Add("Price");
CodeBlock cb = new CodeBlock();
UFWebClientGridAdapter gridAdapter = new UFWebClientGridAdapter(this.DataGrid8);
gridAdapter.IsPostBack = true;
gridAdapter.PostBackTag = "OnCellDataValueChanged";
cb.TargetControls.addControl(gridAdapter);
assocControl.addBlock(cb);
UFGrid itemGrid = this.DataGrid8 as UFGrid;
itemGrid.GridCustomerPostBackEvent += new GridCustomerPostBackDelegate(GridCellOnChanged_DoCustomerAction_Grid);
}
评论