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

Setting the value of the "Bar Rating" example

3 Answers 43 Views
Rating
This is a migrated thread and some comments may be shown as answers.
madladuk
Top achievements
Rank 2
madladuk asked on 11 Nov 2010, 01:50 PM
Hi.

I am trying to use the example code for the bar rating, however how do I set the value? I have a progress value which will be between 0 and 100 in steps of 5. I want to bind this value to the bat to show the progress.

Thanks
P

3 Answers, 1 is accepted

Sort by
0
Viktor Tsvetkov
Telerik team
answered on 11 Nov 2010, 02:13 PM
Hello madladuk,

The value of the rating control is based on the number of items that it contains. So if you want the exactly same bar rating with 5 items and you want to have a progress from 0 to 100 in steps of 5, you need to increment the value for the rating with 0.25 for each step, so finally you will get 5x20 = 100 -> 0.25x20 = 5. If you need more help on this feel free to ask.

Best wishes,
Viktor Tsvetkov
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
0
madladuk
Top achievements
Rank 2
answered on 15 Nov 2010, 03:47 PM
Many thanks, could you tell me how I can set the height of the various bars so that each style is the same height?

P
0
Viktor Tsvetkov
Telerik team
answered on 16 Nov 2010, 10:59 AM
Hi madladuk,

In order to have items with same height you can just copy the Path element from the item that has the desired height and paste it to all other items.

Regards,
Viktor Tsvetkov
the Telerik team
See What's New in RadControls for Silverlight in Q3 2010 on Tuesday, November 16, 2010 11:00 AM - 12:00 PM EST or 10:00 PM - 11:00 PM EST: Register here>>
Tags
Rating
Asked by
madladuk
Top achievements
Rank 2
Answers by
Viktor Tsvetkov
Telerik team
madladuk
Top achievements
Rank 2
Share this question
or