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

Reporting Crosstab error

1 Answer 163 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
Sekar
Top achievements
Rank 1
Sekar asked on 08 Apr 2009, 10:58 PM
Hi there
   I am newbie to this Telerik Reporting and trying to get use to simple reporting stuff with crosstabs. I have a simple datatable that need to be shown as exactly in report and counting the totals.
Design:
  •  Having a cross tab control with text fields as exactly populated in DataTable, in the Detail Section.
  • Having a Chart control in the Detail Section
  • DataFields are assigned in the Value Property of textboxes like "=Fields.<ColumnName>"

Code:
  • At the constructor level, i loaded the Report Page datasource with the DataTable i have.
  • Chart NeedDataSource event also loads the chart's datasource with the datatable.

Problem:
  •  Though the Chart loads the data perfectly, the cross tab throws instantiation error (Object reference not set) on each of the textbox those value property are set to "=Fields.<ColumnName>".
  • And also i see chart and this cross tab with one data row (with error text on each bounded column) per report page and is repeated in seperate Report Pages for the number of rows i have in the DataTable.

Questions:
  • Please explain me the behaviour of why the report page is repeated the times of records.Is that because i load the datasource to the page  like this.Datasource = dataTableObj;  in the Report Page constructor. But i referred the examples you guys gave in CSharp.ReportLibrary Dashboard example for loading the crosstabs in Detail Section and i just followed that. Please correct me where i am wrong
  • Also suggest me the best way to show simple tabular data in reports that can extend more than a page.

I greatly appreciate any guidance from this active community sooner.

Thanks in advance

1 Answer, 1 is accepted

Sort by
0
Chris Gillies
Top achievements
Rank 1
answered on 10 Apr 2009, 01:57 PM
Sekar, it seems that you picked up the wrong sample report to make conclusions. In general the report is kind of a repeater with predefined templates and rules to follow. So the table/crosstab/list items that Telerik released, just make it more obvious. Take a look for example at the ProductCatalog or ProductLineSales reports. In the ProductCatalog the table item is in a groupHeader (and not in the detail section) exactly because it does not have to be repeated the number of rows that come from the report's datasource. In the other report - ProductLineSales, the table can be in the detail section, because the report itself is not databound. My suggestion is to check the following topics:

The table would extend on the next page by default, but I believe that it currently does not support repeating table headers and horizontal spanning (http://www.telerik.com/community/forums/reporting/telerik-reporting/paging-report-on-row-and-column.aspx).

Cheers
Dd
Tags
General Discussions
Asked by
Sekar
Top achievements
Rank 1
Answers by
Chris Gillies
Top achievements
Rank 1
Share this question
or