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

Scaling a sub-report chart by passed parameter

2 Answers 52 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
Peadar
Top achievements
Rank 1
Peadar asked on 08 Feb 2016, 02:29 PM

I'm working on a calendar report that uses a daily sub-report for each day of the month.

The issue I'm running into is that with auto-scaling, each day scales differently based on the data for that day, meaning that the sub-reports are all displayed using different scales, and so don't lend themselves to side-by-side comparison.

It's impossible to know before run-time what the maximum scale for the entire month will be, so I can't hard set the axis scales either. Is there a way to 'pass in' the required scale to the sub-report along with the other parameters? I tried to put a formula in the CoordinateSystem.YAxis.Scale.Maximum property, but it seems to only accept a hard value and not a formula.

2 Answers, 1 is accepted

Sort by
0
Accepted
Nasko
Telerik team
answered on 09 Feb 2016, 11:15 AM
Hello Peadar,

The Maximum property does not support expressions, but you can add a Binding to set this property using an expression.
The binding should be added to the Graph.CoordinateSystems.Bindings collection. The needed property path is XAxis.Scale.Maximum or YAxis.Scale.Maximum depending on your chart type.

Regards,
Nasko
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
Peadar
Top achievements
Rank 1
answered on 12 Feb 2016, 09:25 AM
Perfect, thanks! Hadn't worked with bindings before, extremely useful feature!
Tags
General Discussions
Asked by
Peadar
Top achievements
Rank 1
Answers by
Nasko
Telerik team
Peadar
Top achievements
Rank 1
Share this question
or