I currently have a RadGrid (MainGrid) that contains a Template Column. This Template Column itself contains a separate RadGrid (SubGrid).
The MainGrid has an EditFormTemplate in which I have an ASP.NET PlaceHolder. During MainGrid's ItemCreated event, I check to make sure the Item is in EditMode, instantiate a new RadGrid, and make this new RadGrid equal to the SubGrid (SubGridEdit). During runtime, SubGridEdit displays perfectly fine with all of the correct columns and data, but any attempt during the MainGrid's ItemCommand or UpdateCommand events to access the data rows fails. Everything appears to be fine, but the application is reporting that SubGridEdit has 0 items in its collection.
During MainGrid's ItemCreated event, I have verified that SubGridEdit (a copy of SubGrid that is added to my Placeholder) contains Items in its collection, but once the application moves to the UpdateCommand or ItemCommand events for MainGrid, I'm lost. I'm able to access SubGridEdit by using the FindControl method of the GridEditableItem/GridDataItem, but it's reporting no Items in its collection despite them clearly being displayed.
In essence, SubGrid contains data that is tied to each record in MainGrid. Editing MainGrid involves also editing SubGrid. In this case, SubGrid contains a few checkboxes that the user should be able to mark or unmark while editing MainGrid. In order to do so, though, I need to be able to access the controls of the RadGrid inside of the EditFormTemplate. Any pointers?
Here's the ItemDataBound and ItemCreated events for the MainGrid and the relevant ASPX (Names/IDs changed to examples for security purposes)