Ajax Rating control CurrentRating as double

  • Thread starter Thread starter Joe
  • Start date Start date
J

Joe

I want the CurrentRating to be a double instead of an int. I made the
changes in the code but now the stars always fill with 1 more then it should
if the CurrentRating has a decimal value.

I tried to change the RenderContents method too:
int currentRating = Convert.ToInt32(Math.Floor(this.CurrentRating));

But this still doesn't do anything. I can see in the loop below where it is
setting the class that it sets the fill and empty the right number of times
but when the page displays there is one for.

For example if the CurrentRating = 3.2. There will be 4 stars colored in.

Is there another place that this need to be changed as well?

Thanks,
Joe
 
It looks like there were a few places in the .js code that I didn't notice
before that needed a Math.floor();
 
Back
Top