|
Home : Silverlight UI Components
: Rating1
|
Rating Silverlight Component
|
|
Summary:
|
Rate anything with this versatile component. Allow change in ratings or simply show
current rating. Limit number of times rating can be saved. Fully customizable. Sample
code provided.
|
Price:
|
|
|
|
|
Example 1: Default style
|
|
|
View XML configuration
file
|
|
|
|
Example 2: Styled, updatable, initial value set to 2 stars, limit to 5 submits
|
|
|
View XML configuration
file
|
|
|
|
Example 3: Styled, not updatable, 4 stars
|
|
|
View XML configuration
file
|
|
|
Add this component in 4 easy steps
- Download XAP file and place
it in /ClientBin folder of your web project:
- Download XML configuration file and
add it to your web project (right click, select 'Save Target As'):
- Add HTML code below to your web page:
- Add new Web Page, name it Service.aspx. Add code to process posted data from users.
Sample code: C#
- Customize your component by changing values in XML configuration file:
- Width - defines width of the control. Default: 130
- Height - defines height of the control. Default: 24
- Backgroundcolor - defines background color of the control
in RGB format. Default: 255.255.255 (white)
- Updatable - defines if rating can be changed. Values: Yes,
No. Default: Yes
- InitialValue - sets initial rating (highlighted stars).
Values: 0 to 5. Default: 0
- MaximumSubmits - defines limit on number of successful
submits. Maximum value: 50. Default: 1
- BottomLayerBorderColor - defines border color of unselected
star in RGB format. Default: 150.150.150 (gray)
- BottomLayerBackgroundColor - defines background color of
unselected star in RGB format. Default: 255.255.255 (white)
- BottomLayerBorderThickness - defines border thickness of
unselected star. Values: 0 to 20. Default: 1
- TopLayerBorderColor - defines border color of selected
star in RGB format. Default: 0.30.175 (dark blue)
- TopLayerBackgroundColor - defines background color of selected
star in RGB format. Default: 0.78.255 (blue)
- TopLayerBorderThickness - defines border thickness of selected
star. Values: 0 to 20. Default: 1
- SaveDataTo - defines URL where data will be sent in XML
format (POST method). No Default value.
Sample code C# to read posted
data on web server.
- Key - any value that represent id of an item to be rated.
When user provides rating, Key value is sent to the web server along with number
representing number of stars. Possible values can be product id, image id, page
id, etc. Default: empty
|
|
|
|
Other info:
Support:
|
|
|