I have grids populating a RadPanelBar that are created entirely from the codebehind using advanced data binding. I have a GridEditCommandColumn in this grid. When I click "Edit", ItemCommand is fired followed by EditCommand. At this time, the column displays "Update Cancel". Clicking either of these causes a postback, but ItemCommand does not fire. Nor does UpdateCommand or CancelCommand. As you can see in my .cs, I've attached every command handler I could find trying to find something triggered when I click Update or Cancel with no luck. Any help would be great.
ASPX <!-- 2013.3.1114.40 -->
CS
ASPX <!-- 2013.3.1114.40 -->
<
telerik:RadPanelBar
runat
=
"server"
ID
=
"ClientProductPanels"
Width
=
"100%"
AllowCollapseAllItems
=
"false"
ExpandMode
=
"SingleExpandedItem"
/>
CS
private
RadGrid PopulatePanelGrid(
string
referrer)
{
RadGrid productGrid =
new
RadGrid();
productGrid.AllowPaging =
false
;
productGrid.AllowSorting =
false
;
productGrid.AllowAutomaticInserts =
true
;
productGrid.AllowAutomaticDeletes =
true
;
productGrid.AllowAutomaticUpdates =
true
;
productGrid.AutoGenerateEditColumn =
true
;
productGrid.AutoGenerateDeleteColumn =
true
;
productGrid.MasterTableView.AutoGenerateColumns =
false
;
productGrid.MasterTableView.EditMode = GridEditMode.InPlace;
productGrid.ID = referrer;
productGrid.DeleteCommand +=
new
GridCommandEventHandler(productGrid_DeleteCommand);
productGrid.CancelCommand +=
new
GridCommandEventHandler(productGrid_CancelCommand);
productGrid.BatchEditCommand +=
new
GridBatchEditEventHandler(productGrid_BatchEditCommand);
productGrid.ItemDeleted +=
new
GridDeletedEventHandler(productGrid_ItemDeleted);
productGrid.ItemCommand +=
new
GridCommandEventHandler(productGrid_ItemCommand);
productGrid.ItemEvent +=
new
GridItemEventHandler(productGrid_ItemEvent);
productGrid.ItemInserted +=
new
GridInsertedEventHandler(productGrid_ItemInserted);
productGrid.ItemUpdated +=
new
GridUpdatedEventHandler(productGrid_ItemUpdated);
productGrid.InsertCommand +=
new
GridCommandEventHandler(productGrid_InsertCommand);
productGrid.EditCommand +=
new
GridCommandEventHandler(productGrid_EditCommand);
productGrid.UpdateCommand +=
new
GridCommandEventHandler(productGrid_UpdateCommand);
productGrid.ItemDataBound +=
new
GridItemEventHandler(productGrid_ItemDataBound);
productGrid.ItemCreated +=
new
GridItemEventHandler(productGrid_ItemCreated);
productGrid.NeedDataSource +=
new
GridNeedDataSourceEventHandler(productGrid_NeedDataSource);
GridCheckBoxColumn checkColumn =
new
GridCheckBoxColumn();
checkColumn.UniqueName =
"Checked"
;
checkColumn.DataField =
"Selected"
;
checkColumn.ReadOnly =
true
;
checkColumn.HeaderStyle.Width = Unit.Pixel(20);
checkColumn.ItemStyle.Width = Unit.Pixel(20);
checkColumn.ItemStyle.HorizontalAlign = HorizontalAlign.Center;
productGrid.MasterTableView.Columns.Add(checkColumn);
GridBoundColumn boundColumn =
new
GridBoundColumn();
boundColumn.DataField =
"ProductName"
;
boundColumn.HeaderText =
"Product Name"
;
boundColumn.ReadOnly =
true
;
productGrid.MasterTableView.Columns.Add(boundColumn);
GridNumericColumn numericColumn =
new
GridNumericColumn();
numericColumn.DataField =
"Fee"
;
numericColumn.HeaderText =
"Fee"
;
numericColumn.UniqueName =
"Fee"
;
numericColumn.DataFormatString =
"{0:C}"
;
numericColumn.DecimalDigits = 2;
numericColumn.MaxLength = 7;
numericColumn.NumericType = NumericType.Currency;
numericColumn.HeaderStyle.Width = Unit.Pixel(110);
numericColumn.HeaderStyle.HorizontalAlign = HorizontalAlign.Right;
numericColumn.ItemStyle.Width = Unit.Pixel(110);
numericColumn.ItemStyle.HorizontalAlign = HorizontalAlign.Right;
productGrid.MasterTableView.Columns.Add(numericColumn);
boundColumn =
new
GridBoundColumn();
boundColumn.DataField =
"AverageFee"
;
boundColumn.HeaderText =
"Average Fee"
;
boundColumn.DataFormatString =
"{0:C}"
;
boundColumn.ReadOnly =
true
;
boundColumn.HeaderStyle.Width = Unit.Pixel(110);
boundColumn.HeaderStyle.HorizontalAlign = HorizontalAlign.Right;
boundColumn.ItemStyle.Width = Unit.Pixel(110);
boundColumn.ItemStyle.HorizontalAlign = HorizontalAlign.Right;
productGrid.MasterTableView.Columns.Add(boundColumn);
boundColumn =
new
GridBoundColumn();
boundColumn.DataField =
"ProductID"
;
boundColumn.ReadOnly =
true
;
boundColumn.Display =
false
;
productGrid.MasterTableView.Columns.Add(boundColumn);
GridEditCommandColumn editColumn =
new
GridEditCommandColumn();
editColumn.ItemStyle.Width = Unit.Pixel(75);
editColumn.UniqueName =
"Edit"
;
editColumn.EditText =
"Add/Edit Fee"
;
productGrid.MasterTableView.Columns.Add(editColumn);
return
productGrid;
}