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

Report Header

6 Answers 418 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
Ramon
Top achievements
Rank 1
Ramon asked on 29 May 2007, 07:08 PM
Hello

I created a report header in my report and i want to show some datafields i mean some information there but when y preview my report i get the next error:

Object reference not set to an instance of an object.

Need Help.

Thanks.

6 Answers, 1 is accepted

Sort by
0
Ivan
Telerik team
answered on 30 May 2007, 04:54 PM
Hi Ramon,

At present you cannot bind items in the ReportHeader or ReportFooter sections to data fields. We plan to implement this functionality in version 2 of Telerik Reporting which is due next year.

 
Kind regards,
Ivan
the Telerik team

Instantly find answers to your questions at the new Telerik Support Center
0
Ramon
Top achievements
Rank 1
answered on 30 May 2007, 06:29 PM
Ok, thanks for the comment.

I have one more question, can i create sub report headers?? like the ones on crystal and can i bind items there?

Thank you for your time.
0
Hrisi
Telerik team
answered on 31 May 2007, 05:13 PM
Hello Ramon,

In your master report it is not possible to bind data in header section controls, but in upcoming SP1 this is fixed. In the current you can have a subreport in the header section - feel free to try it.

The service pack is due this week and we will have an official announcement in the Announcements Forum once it is live. If you are not subscribed to the Announcements RSS already, please use this link: http://www.telerik.com/support/rss/b254P-b-b254A-bga.aspx

 
Sincerely yours,
Hrisi
the Telerik team

Instantly find answers to your questions at the new Telerik Support Center
0
MikeK
Top achievements
Rank 1
answered on 18 Oct 2007, 05:46 PM
Has this been addressed in vs 1.5?

If I can't databind to a field in the page or report header, could I bind to a parameter?

Both SQL Reporting Service and Xtrareports have this limitation but can be addressed by binding to a report parameter. Is the same possible here? If yes, do you have any examples?
0
Hrisi
Telerik team
answered on 19 Oct 2007, 04:26 PM
Hi Michael Kober,

There is no problem to use databound report items in all sections. The only place where this doesn't work is the PageHeader/Footer section.

This is not a limitation of the reporting engine, however. The header/footers are page attributes (i.e. rendering items) and do not relate to report data.
 
Of course, you can use report parameters to bind data to the report items placed in the PageHeader/Footer, but you should know exactly how the report is processed. During the processing stage of the report all parameter values are evaluated before data binding, and those are not being bound to the data by the reporting engine itself.

To relate parameter to data you can programmatically instantiate the report, set the report parameter value to what you want, and then show it. You can learn more on parameters in the provided documentation.
 

Kind regards,
Hrisi
the Telerik team

Instantly find answers to your questions at the new Telerik Support Center
0
Guillermo Andres
Top achievements
Rank 1
answered on 19 Jun 2008, 08:51 PM

Hi everyone,

I had the same problem when trying to bind on header textboxes. The solution I found was to create a class within the report project to hold all the data I want it in the headers as static fields. Latter in the constructor of the report I just assign each static field with its corresponding textbox.

I hope this could help.

Tags
General Discussions
Asked by
Ramon
Top achievements
Rank 1
Answers by
Ivan
Telerik team
Ramon
Top achievements
Rank 1
Hrisi
Telerik team
MikeK
Top achievements
Rank 1
Guillermo Andres
Top achievements
Rank 1
Share this question
or