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

Duplicate Y-Axis on chart

2 Answers 87 Views
Chart
This is a migrated thread and some comments may be shown as answers.
Steven
Top achievements
Rank 1
Steven asked on 14 Apr 2015, 10:05 AM

Hi,

We have had a request from a user who asked if we can show the Y-Axis on both sides of a chart. Is there an easy way to do this using your charts for WPF? The only approach to achieving this that I can see is to have two of each series but assign them to different axes. I would prefer not to do it this way if we can avoid it.

Thanks,

Steven

2 Answers, 1 is accepted

Sort by
0
Accepted
Petar Marchev
Telerik team
answered on 16 Apr 2015, 08:55 AM
Hello Steven,

We have two charting solutions - the old RadChart and the new RadChartView. The new chartview is actually a set of controls - RadCartesianChart, RadPieChart, RadPolarChart and ChartDataSource. We strongly suggest you do not start new development with the old RadChart, but use only the new one.

I am a little unsure which of the two you use, so I will provide answer for the two. If you need further assistance, please confirm which control you are using.

RadChart
The old chart has an additional-axes feature, which allows you to add an arbitrary number of additional axes. This is explained in our online help article here.

ChartView
The chartview has a multiple-axes feature (qsf examples here, online documentation here). This is a bit different. While the chart can work with more than one axis, each axis (except the main axis) needs to be associated with at least one series, in order to be added to the chart. For example, if you have only one series - you can have only one axis. If you have two series, you can have no more than two axes.

In cases, where you need to show two axes and a single series, we suggest you add a dummy series, which has no data. This dummy series will not be displayed, but you can use it in order to attach a new axis. You can then bind the min, max, step properties of this axis to the properties of the main axis.

I have attached a simple example that demonstrates both approaches.

Regards,
Petar Marchev
Telerik
 

See What's Next in App Development. Register for TelerikNEXT.

 
0
Steven
Top achievements
Rank 1
answered on 17 Apr 2015, 10:21 AM

Hi,

Sorry I am using ChartView, I stopped scrolling when I got to Cloud Platform and only saw the one Chart forum (for some reason ChartView is sorted after Cloud Platform, I assumed the list was sorted alphabetically?).

 Thanks for your help, the Dummy series approach and binding min/max/step of the main axis will work.

 

Thanks for your help.

Steven

 

 

Tags
Chart
Asked by
Steven
Top achievements
Rank 1
Answers by
Petar Marchev
Telerik team
Steven
Top achievements
Rank 1
Share this question
or