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

e.GetPosition(_radChartArea) convert to x and y scale value and vice versa

1 Answer 49 Views
Chart
This is a migrated thread and some comments may be shown as answers.
leblanc
Top achievements
Rank 1
leblanc asked on 17 Aug 2010, 05:23 PM
> e.GetPosition(_radChartArea) convert to x and y scale value and vice versa

I'm trying to use a radchart and need to provide the user control handles to modify a MarkedZone.

Is there an existing api I can use to translate back and forth from x/y scale in chartarea to point relative to chartarea?
 

1 Answer, 1 is accepted

Sort by
0
Vladimir Milev
Telerik team
answered on 23 Aug 2010, 09:15 AM
Hi leblanc,

There is a method on t he Axis class called ConvertDataUnitsToPhysical.

Its implementation is actually quite simple:
public double ConvertDataUnitsToPhysical(double inputRange)
{
    return ((inputRange / this.ActualRange) * this.Length);
}
It converts data units to their physical length in DIP as measured by the axis.


Regards,
Vladimir Milev
the Telerik team
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 Public Issue Tracking system and vote to affect the priority of the items
Tags
Chart
Asked by
leblanc
Top achievements
Rank 1
Answers by
Vladimir Milev
Telerik team
Share this question
or