I am having a complex issue so let me try to explain. I have a WebHierarchialDataGrid with 3 levels: first level is a name, second level is an action item (description with some dropdowns and buttons), third level is a textbox. For example:
Peter (3)
Do this Yes/No SAVE
Do that Yes/No SAVE
Paul (1)
Crude example...The SAVE is an image button like this:
<
asp:ImageButton ToolTip="Click to save" ImageUrl="../Images/save.gif" ID="btnSave" runat="server" Style="cursor: hand;" CommandArgument='<%# DataBinder.Eval(((Infragistics.Web.UI.TemplateContainer)Container).Item, "Row.Index") %>'OnCommand="btnSave_OnCommand" OnClientClick="return CheckAnswer();"></asp:ImageButton>
First load everything works fine but second load the btnSave_OnCommand event DOES NOT FIRE and therefore a previous grid gets loaded...here is my grid:
ig:WebHierarchicalDataGrid ID="hdgActionItems" AutoGenerateBands="false" Key="Contact"runat="server" AutoGenerateColumns="false" InitialDataBindDepth="2" InitialExpandDepth="0" OnInitializeRow="hdgActionItems_InitializeRow" onkeypress="if(event.keyCode==13) return false;"Width="972px" DataKeyFields="Personnel_ID" EnableAjax="False">
Any suggestions?
Good ole session variables...no issues now.
Ok I added this:
btn.Command +=
new CommandEventHandler(btnSave_OnCommand);
and now the command fires, HOWEVER when I access the values from the grid, the values are from a PREVIOUS grid and NOT the grid that is currently displayed. Caching issue or something?