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

Compas + radialGauge + WP7

4 Answers 56 Views
Gauge
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
kity
Top achievements
Rank 2
kity asked on 18 Sep 2012, 02:42 PM

 

  .... 


How to set compas offset of angle +-(90), look image.
Zero value must be on the top of RadialGauge. How to do that?

At this point I hide labels and at runtime add +90 degrees.

<gauges:RadialGaugeRange TickStep="45"
                                 LabelStep="45"
                                 MinAngle="0"
                                 MaxAngle="359"                               
                                 MinValue="0"                                
                                 MaxValue="359"
                                  
                                 TickRadiusScale="1"
                                 LabelRadiusScale="0.50"
                                  
                                />



...

4 Answers, 1 is accepted

Sort by
0
Victor
Telerik team
answered on 19 Sep 2012, 06:42 AM
Hi Pet,

You just need to work with the min/max angle properties. In your case, the MinAngle must be 90 and the MaxAngle must be 359 + 90.

Regards,
Victor
the Telerik team

Time to cast your vote for Telerik! Tell DevPro Connections and Windows IT Pro why Telerik is your choice. Telerik is nominated in a total of 25 categories.

0
kity
Top achievements
Rank 2
answered on 19 Sep 2012, 04:56 PM

 if i want to set compass to 10 degree(out of diapason)? What value will show array on compass?

Compass diapason(valid interval) is from 1 to 360 degrees. 

Problem is when degree value is out of diapason. When this happen compass array "dance crazy" and at the end stop to zero default value. This is wrong behavior for compass, but maybe correct for gauge ;)

In silverlight when value is out of interval, array revert and stop to correct value, in wp7 array revert( "dance crazy" ) and stop to zero- wrong value!

0
Accepted
Victor
Telerik team
answered on 25 Sep 2012, 07:17 AM
Hi Pet,

Thanks for the question.
Please clarify what you mean by "out of diapason". Also what "array" are you referring to, is it the gauge range?
I am looking forward to your reply. 

Regards,
Victor
the Telerik team

Time to cast your vote for Telerik! Tell DevPro Connections and Windows IT Pro why Telerik is your choice. Telerik is nominated in a total of 25 categories.

0
kity
Top achievements
Rank 2
answered on 25 Sep 2012, 05:08 PM

In teleric wp7 library must manually write function for calculation degree value

1 step. convert value to degree

2. if value is out of degree compass diapason must use this formula

   x =  Truncate (d / 360.0); // x is type of integer, numbers of reverts, truncate() is missing in WP sdk 7.1, must manually write (usee floore combination)

   d2 = x * d;

   d = Abs(d-d2);

Tags
Gauge
Asked by
kity
Top achievements
Rank 2
Answers by
Victor
Telerik team
kity
Top achievements
Rank 2
Share this question
or