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

Restrict Number of Recrods Per Page in Reporting

3 Answers 641 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
rajesh
Top achievements
Rank 1
rajesh asked on 10 Aug 2015, 05:57 AM

 Please Resolve my problems with Reporting.

1.How to set Dataset  or datatable as Datasource to a Report.

2. set number of records per page

3.Sub Reports in Main Report.

3 Answers, 1 is accepted

Sort by
0
Stef
Telerik team
answered on 11 Aug 2015, 04:38 PM
Hi Rajesh,

On your questions:
  1. You can use an ObjectDatasource that wraps a data retrieval method returning the DataTable object.
    You can also set the data at run-time e.g.:
    var report = new MyReport();
    //set the report's data source
    report.DataSource = GetData();
     
    //set a nested data item's data source
    (report.Items.Find("table1", true)[0] as Telerik.Reporting.Table).DataSource = GetTableData();
     
    //display the report
    var IRS = new InstanceReportSource { ReportDocument = report};
    reportViewer1.ReportSource = IRS;
  2. The report's content is paged based on the designed layout and the report's PageSettings properties - Understanding Pagination.
    In case you are asking how to limit the number of records in the report, you can applying filtering on data retrieval or in the report - Filtering data.
  3. Details how to use SubReport item to display external report in other report are available in How to: Create a Master-Detail Report Using a SubReport Item. Note you can avoid sub reports by using other nested data items like Table/List/Crosstab.


Let us know if you have any further questions.

Regards,
Stef
Telerik
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Feedback Portal and vote to affect the priority of the items
0
rajesh
Top achievements
Rank 1
answered on 12 Aug 2015, 05:20 AM

Hi stef,

           2).in second question i want to display limited records per page.(For example i have 100 rows here i want to display 10  rows in each page like wise i need to display 100 rows in 10 pages in single report).

       Crystal report Solution:   In crystal report we should use below formula to display 10 records per page in single report.

               if Remainder (RecordNumber, 10) = 0 then true else false

0
Stef
Telerik team
answered on 12 Aug 2015, 03:21 PM
Hi Rajesh,

Depending on the report layout, you can add conditionally page breaks to the report sections based on the current row number - Conditional Page Breaks.

Regards,
Stef
Telerik
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Feedback Portal and vote to affect the priority of the items
Tags
General Discussions
Asked by
rajesh
Top achievements
Rank 1
Answers by
Stef
Telerik team
rajesh
Top achievements
Rank 1
Share this question
or