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

Ranges in the XAxis Label

1 Answer 26 Views
Chart (obsolete as of Q1 2013)
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
Sergio
Top achievements
Rank 1
Sergio asked on 24 May 2011, 03:19 PM

Greetings

I have Point Chart Type Graph in WinForms. My client is requiring me to Display range labels for the XAxis, so for instance in the label between tick marks say - 10 to 30, 30 to 50 and so on. In its natural state the graph displays the xvalue, I would need to know the range of data between tick marks in order to provide for a label. Is there a workaround you could suggest?

I really like the Mark Zone approach, as a matter of fact I try this one, and It work really well! My only concern is that the MarkZone Label Displays at the top of the Graph... If I could only manage to display this label right at the bottom (right above the XAxis Line) I could fake the XAxis labels.

Also my client wants me to specify the number of ticks, on the xAxis, and I have not manage to accomplish this - How can I do this, say like have 11 tick marks instead of 5? In addition, My graph for some reason is starting in the xaxis label before zero - even though there is not even xvalues before zero, I try changing XAxis.MinValue but this had not effect.

1 Answer, 1 is accepted

Sort by
0
Evgenia
Telerik team
answered on 27 May 2011, 09:18 AM
Hi Sergio,

You can control the position of the MarkedZone's Label by customizing the values of the MarkedZone.Label.TextBlock.Position property. You can access these from the Properties window as shown in the picture attached.

There is no way to hide some of the MajorTicks of the Axes - you can either turn the visibility off for all of them or for none.

You can control the range of the Axes by the AutoScale property. When turned off you can provide your own MinValue, MaxValue and Step like this:
this.radChart1.PlotArea.XAxis.AutoScale = false;
this.radChart1.PlotArea.XAxis.AddRange(1, 10, 1);

Regards,
Evgenia
the Telerik team
Q1’11 SP1 of RadControls for WinForms is available for download; also available is the Q2'11 Roadmap for Telerik Windows Forms controls.
Tags
Chart (obsolete as of Q1 2013)
Asked by
Sergio
Top achievements
Rank 1
Answers by
Evgenia
Telerik team
Share this question
or