Display Stars That Are Selected Only

2 posts, 0 answers
  1. Christian
    Christian avatar
    1 posts
    Member since:
    Jan 2014

    Posted 29 Jan 2014 Link to this post

    I have a RadGrid that has a radrating control.  That column is readonly.  I am wondering if you can point me in the direction of displaying only the stars that are selected.


    Here I am wondering if we could get it to display where ABC Bank would still show all 5 stars, ABC Company would only show 3.5, and there wouldn't be anything in the column for ABC Owner.
  2. Niko
    Niko avatar
    383 posts

    Posted 30 Jan 2014 Link to this post

    Hello Christian,

    Your best option is to force the background image of the unselected stars to be a transparent image. What you could do is rely on the sprites that come with each skin and just change the background-position of the elements that carry the background image. Here is a sample implementation for the Default skin:
    .RadRating ul li a {
        background-position: 0 -18px;
     Please, note that this will only work when the Rating controls is in ReadOnly="true" state, which as far as I understand is exactly your case.

    Hope this helps.

    If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the UI for ASP.NET AJAX, subscribe to the blog feed now.
  3. DevCraft R3 2016 release webinar banner
Back to Top