This question is locked. New answers and comments are not allowed.
Hello!
I have an issue. I try to change scale ranges dynamically, but it doesn't changed (old range is shown).
This is simple app where it doesn't work:
Xaml:
Click action is very simple:
After buttin click I see old range from 0 to 20. If I call scale.InvalidateMeasure(); then I get new range from 20 to 40, but also I still see old range from 0 to 20.
Is is a bug or I'm doing something wrong?
Thanks, Anatoly Chekh.
I have an issue. I try to change scale ranges dynamically, but it doesn't changed (old range is shown).
This is simple app where it doesn't work:
Xaml:
<
StackPanel
>
<
telerik:RadRadialGauge
Width
=
"220"
Height
=
"220"
>
<
telerik:RadialScale
Name
=
"scale"
RangeLocation
=
"Outside"
RangeOffset
=
"-0.015"
MajorTickOffset
=
"-0.015"
MiddleTickOffset
=
"-0.015"
MinorTickOffset
=
"-0.015"
LabelRotationMode
=
"None"
>
<
telerik:RadialScale.Ranges
>
<
telerik:GaugeRange
Min
=
"0"
Max
=
"20"
StartWidth
=
"0.015"
EndWidth
=
"0.015"
Background
=
"Green"
/>
</
telerik:RadialScale.Ranges
>
</
telerik:RadialScale
>
</
telerik:RadRadialGauge
>
<
Button
Content
=
"Click"
Click
=
"ButtonBase_OnClick"
/>
</
StackPanel
>
Click action is very simple:
private
void
ButtonBase_OnClick(
object
sender, RoutedEventArgs e)
{
scale.Ranges.Clear();
scale.Ranges.Add(
new
GaugeRange() { Min = 20, Max = 40, StartWidth = 0.015, EndWidth = 0.015, Background =
new
SolidColorBrush(Colors.Green) });
}
After buttin click I see old range from 0 to 20. If I call scale.InvalidateMeasure(); then I get new range from 20 to 40, but also I still see old range from 0 to 20.
Is is a bug or I'm doing something wrong?
Thanks, Anatoly Chekh.