This is a migrated thread and some comments may be shown as answers.

nested view with data repeater

1 Answer 138 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
Dorian Yeager
Top achievements
Rank 1
Dorian Yeager asked on 28 Dec 2009, 01:36 AM
All,

Is it possible to use a nested view that contains a data repeater to loop through all the results of the secondary datasource?
Please provide an example if possible or point me toward example code.

Thanks in advance,
Dorian

1 Answer, 1 is accepted

Sort by
0
Shinu
Top achievements
Rank 2
answered on 30 Dec 2009, 11:37 AM
Hello Dorian,

I suppose you want to display the results of a secondary datasource in a Repeater control which is inturn placed inside the NestedViewTemplate of the grid. If thats the case, then you can check out the following example:
aspx:
<telerik:RadGrid ID="RadGrid1" DataSourceID="SqlDataSource1" runat="server"
    <MasterTableView DataSourceID="SqlDataSource1">                    
          <NestedViewTemplate> 
               <asp:Repeater DataSourceID="SqlDataSource2" runat="server" ID="Repeater"
                   <ItemTemplate> 
                         <asp:Label ID="Label1" runat="server" Text='<%#Eval("ProductName") %>'></asp:Label> 
                   </ItemTemplate> 
              </asp:Repeater>                      
        </NestedViewTemplate> 
       <Columns> 
         ....               
       </Columns> 
    </MasterTableView>                
</telerik:RadGrid> 

If this does not help, please explain in detail what you require with probably an image.
-Shinu.
Tags
General Discussions
Asked by
Dorian Yeager
Top achievements
Rank 1
Answers by
Shinu
Top achievements
Rank 2
Share this question
or