Hi,
I am trying to create a page with nested data lists to show nested information.
I have a stored procedure that returns a data set with 4 tables in it.
I am creating the data relations as follows
and in the nested datalist
When I add one data relation and display the corresponding datalist it works. As soon as I try to add the second relation I get the error
"Public member 'Row' on type 'DataRow' not found."
Any help would be appreciated
I am trying to create a page with nested data lists to show nested information.
I have a stored procedure that returns a data set with 4 tables in it.
I am creating the data relations as follows
Code:
oRelation = New DataRelation("ReportPeriods", oDS.Tables(0).Columns("iClassID"), oDS.Tables(1).Columns("iClassID"), False)
oRelation.Nested = True
oDS.Relations.Add(oRelation)
oRelation = New DataRelation("Categories", oDS.Tables(1).Columns("iReportPeriodID"), oDS.Tables(2).Columns("iReportPeriodID"), False)
oRelation.Nested = True
oDS.Relations.Add(oRelation)
oRelation = New DataRelation("Tasks", oDS.Tables(2).Columns("cCategoryID"), oDS.Tables(3).Columns("ccategoryID"), False)
oRelation.Nested = True
oDS.Relations.Add(oRelation)
dlClass.DataSource = oDS
dlClass.DataBind()
and in the nested datalist
Code:
<asp:DataList id="dlReportPeriod" runat="server" DataSource='<%#Container.DataItem.Row.GetChildRows("ReportPeriods")%>'>
When I add one data relation and display the corresponding datalist it works. As soon as I try to add the second relation I get the error
"Public member 'Row' on type 'DataRow' not found."
Any help would be appreciated