Hi,
I have a RadGrid with Hierarchy. I would like to access the DataKeyValues (parent/master table Key Values) in the DetailTables' <CommandItemTemplate>.
Here is the code snippet,
<DetailTables>
<telerik:GridTableView DataKeyNames="DV_Correlation_Detail_ID" DataSourceID="dsrcCorrDetail" HierarchyDefaultExpanded="true" ShowHeader="true" ShowFooter="false"
Width="100%" runat="server" AllowFilteringByColumn="False" CommandItemDisplay="Top" Name="Correlation_Detail" EditMode="InPlace">
<ParentTableRelation>
<telerik:GridRelationFields DetailKeyField="DV_Correlation_ID" MasterKeyField="DV_Correlation_ID" />
</ParentTableRelation>
<CommandItemTemplate>
<a href="Javascript:showDialog(1,'derived_variable_selection.aspx?CorrID=<%# Eval("DV_Correlation_ID") %>');"><img style="border:0px" alt="Add Independent Variable" src="images/AddRecord.gif" /> Add Independent Variable </a>
</CommandItemTemplate>
When I do "Eval()", it did not complain, and it did not return any value, either. How can I get the key value for each hierarchy detail table within CommandItemTemplate?
Any assistance will be very much appreciated.
Thanks,
Arthur W.
I have a RadGrid with Hierarchy. I would like to access the DataKeyValues (parent/master table Key Values) in the DetailTables' <CommandItemTemplate>.
Here is the code snippet,
<DetailTables>
<telerik:GridTableView DataKeyNames="DV_Correlation_Detail_ID" DataSourceID="dsrcCorrDetail" HierarchyDefaultExpanded="true" ShowHeader="true" ShowFooter="false"
Width="100%" runat="server" AllowFilteringByColumn="False" CommandItemDisplay="Top" Name="Correlation_Detail" EditMode="InPlace">
<ParentTableRelation>
<telerik:GridRelationFields DetailKeyField="DV_Correlation_ID" MasterKeyField="DV_Correlation_ID" />
</ParentTableRelation>
<CommandItemTemplate>
<a href="Javascript:showDialog(1,'derived_variable_selection.aspx?CorrID=<%# Eval("DV_Correlation_ID") %>');"><img style="border:0px" alt="Add Independent Variable" src="images/AddRecord.gif" /> Add Independent Variable </a>
</CommandItemTemplate>
When I do "Eval()", it did not complain, and it did not return any value, either. How can I get the key value for each hierarchy detail table within CommandItemTemplate?
Any assistance will be very much appreciated.
Thanks,
Arthur W.