Is it possible to dynamically produce charts in a ReportViewer? (bar, pie, and line charts)
I managed to make RadCharts in a User Control, but I can't seem to produce anything inside a ReportViewer.
My data source (for the chart) is an array, and I'm using WPF.
2 Answers, 1 is accepted
0
Accepted
Stef
Telerik team
answered on 13 Aug 2014, 02:29 PM
Hi Darius,
I believe we already discussed the same question in your support ticket #848137.
For anyone concerned, below is my reply from the ticket:
"Telerik report is a template repeated for the assigned to it data. Report can be created through our Report Designers, or dynamically.
Using the provided report designers will ease you to create the desired layout. When you use the integrated in Visual Studio Report Designer you will be able to get the auto-generated code in the report's designer.cs(vb) file and modify and reuse it to build a report from scratch.
The created report can be displayed in a WPF ReportViewer. an example of using the WPF ReportViewer is available in our local demos, installed by default under C:\Program Files (x86)\Telerik\Reporting Q2 2014\Examples\CSharp\WpfDemo.
If you need to specifically create a chart, you can use the Graph item and report designers to create the desired layout. Then just reuse the generated code.Each chart type has a description and tutorial how to create the chart - Chart Types.
Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.
In case it might help anyone else: I had to set my List (which is the data source) as static, so that it provides as a global data source to both the ReportViewer and my other classes that populate it.