5 Answers, 1 is accepted
0
Hi kmv,
The Preview would work for reports bound through NeedDataSource as well.
All the best,
Steve
the Telerik team
Instantly find answers to your questions on the new Telerik Support Portal.
Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
The Preview would work for reports bound through NeedDataSource as well.
All the best,
Steve
the Telerik team
Instantly find answers to your questions on the new Telerik Support Portal.
Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
0

kmv
Top achievements
Rank 1
answered on 30 Nov 2009, 04:37 PM
ok steve thanks for that ...
all i have to do now is figure out why my report wont display in the preview tab
regards
kevin
all i have to do now is figure out why my report wont display in the preview tab
regards
kevin
0

kmv
Top achievements
Rank 1
answered on 30 Nov 2009, 10:45 PM
steve
my report runs if i run the web application but in preview i get
An error has occured while processing Report '':
Object reference not set to an instance of an object.
any ideas
kevin
my report runs if i run the web application but in preview i get
An error has occured while processing Report '':
Object reference not set to an instance of an object.
any ideas
kevin
0
Accepted
Hello kmv,
Are you by any chance using web site and host the reports within the App_Code folder? If this is the case, then it is expected that Previews do not work due to limitation of the web site projects. We recommend using a separate class library to hold your reports and reference that class library in your web/win application.
If this is not the case, please share more info about your exact scenario (what is your datasource, where is it located etc.).
Please note that Telerik Report Designer operates inside the Visual Studio application. When previewing a report, the project that contains the report is compiled (if needed) and the report class is instantiated through Reflection, and passed to the previewer. This means that the report constructor is executed in the context of the Visual Studio application and the report that is previewed will get all connection strings defined in the devenv.exe.config file.
Obviously this is not the right configuration file that one may expect, so the trick is to use the application settings. This is what the Report and Data Source Wizards actually do when instructed to save the selected connection string in the config file.
If you are still having problems, please open a support ticket and attach a sample application (or your actual one) showing the problem at hand.
Regards,
Steve
the Telerik team
Instantly find answers to your questions on the new Telerik Support Portal.
Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
Are you by any chance using web site and host the reports within the App_Code folder? If this is the case, then it is expected that Previews do not work due to limitation of the web site projects. We recommend using a separate class library to hold your reports and reference that class library in your web/win application.
If this is not the case, please share more info about your exact scenario (what is your datasource, where is it located etc.).
Please note that Telerik Report Designer operates inside the Visual Studio application. When previewing a report, the project that contains the report is compiled (if needed) and the report class is instantiated through Reflection, and passed to the previewer. This means that the report constructor is executed in the context of the Visual Studio application and the report that is previewed will get all connection strings defined in the devenv.exe.config file.
Obviously this is not the right configuration file that one may expect, so the trick is to use the application settings. This is what the Report and Data Source Wizards actually do when instructed to save the selected connection string in the config file.
If you are still having problems, please open a support ticket and attach a sample application (or your actual one) showing the problem at hand.
Regards,
Steve
the Telerik team
Instantly find answers to your questions on the new Telerik Support Portal.
Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
0

kmv
Top achievements
Rank 1
answered on 01 Dec 2009, 08:47 AM
steve
thanks for that explanation really useful, unfortunately my report is in a class library in a web application. I have a commented in line for the data source (a SQL server DB) and am using a linq statement i my needdatasource.
as per your recommendation i will play around but if i get no where will put on a support ticket
thanks
kevin
thanks for that explanation really useful, unfortunately my report is in a class library in a web application. I have a commented in line for the data source (a SQL server DB) and am using a linq statement i my needdatasource.
as per your recommendation i will play around but if i get no where will put on a support ticket
thanks
kevin