Dataset with multiple DataTables

2 posts, 0 answers
  1. mkasuboski
    mkasuboski avatar
    17 posts
    Member since:
    Jul 2008

    Posted 08 Apr 2009 Link to this post

    I was wondering if I can set a report's datasource equal to a Dataset that contains multiple datatables, and in the code-behind for the report set the different sections to a specific table from the dataset, i.e. the ReportHeader Section, the Detail Section, etc.

    This code would be in the ASPX page to create the dataset and datatables, and then bind them to the report.
                Dim mainDataSource As New DataSet 
                Dim rptHeader As New DataTable("rptHeader"
                Dim rptDetail As New DataTable("rptDetail"
                Dim rptFooter As New DataTable("rptFooter"
                Dim sampleReport As New MySampleReport 
                sampleReport.DataSource = mainDataSource 

    So is there a way in the report to bind a specific section to a table out of the dataset?

  2. Steve
    Steve avatar
    10940 posts

    Posted 09 Apr 2009 Link to this post

    Hi mkasuboski,

    The DataSource can be set only once directly to the report and is applicable for the whole report (all sections). For your scenario you might take advantage of the subreport and table report items.

    Kind regards,
    the Telerik team

    Check out Telerik Trainer , the state of the art learning tool for Telerik products.
Back to Top