I am stuck here.
I have a GridView with another GridView (As A Template Column as a User Control) nested in it.
Both are bound to an ObjectDataSource. My Problem now is how I pass the ID from the Parent Row to the Child Grid in order to only show the relevant data.
Example:
<ParentGridView>
<Columns>
<ID/>
<ChildGridView/>
</Columns>
</ParentGridView>
How can i pass the ID from ParentGridView to ChildGridView ?
Thank you.
try something like this
or
var gvParent= (GridViewRow)gvChild.Parent.Parent.Parent;Also have a look at this article about Creating a Nested GridView Control