We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy.
Unfortunately, activation email could not send to your email. Please try again.

I can not configure SfRating...

Thread ID:

Created:

Updated:

Platform:

Replies:

130466 May 14,2017 09:51 PM May 18,2017 05:39 AM Xamarin.Forms 6
loading
Tags: SfRating
Luis Alfredo
Asked On May 14, 2017 09:51 PM

I'm new using Syncfusion.
I think the documentation is obsolete. It says to use this sintax:
 x:Name="ratingSettings" RatedFill="Red" />
It doesn't work. I try this:
<rating:SfRating x:Name="Rating" Value="4" ItemSize="20" HorizontalOptions="Center">
                <rating:SfRatingSettings RatedFill="#F6FF00"/>
            </rating:SfRating>
Doesn"t work RatedFill neither HorizontalOptions="Center"
The stars come at left and with default collor blue...
Any tip?
Thanks in advance...



Rathana Kumar Sekar [Syncfusion]
Replied On May 15, 2017 06:29 AM

Hi Luis,

Thanks for contacting Syncfusion Support.

We have prepared the sample for you and which we have implemented the SfRating. Please find the sample from the below link.

We will correct our UG documentation and we will republish the UserGuide in upcoming release Volume 3, 2017.

Regards,
Rathanakumar S.


Luis Alfredo Stockler Filho
Replied On May 15, 2017 10:38 AM

Thank you Rathama for your answer.

RatedFill is working now but HorizontalOptions = "Center" does not work in any way...

Look may code, I have a StackLayout vertical with 2 elements: SfRating and a Button. Both with center alignment.
The Button align as expected in center but SfRating only align at left...

            <StackLayout Orientation="Vertical">
                <rating:SfRating       ItemCount="5"
                                       Value="3.6"
                                       Precision="Exact"
                                       TooltipPlacement="None"
                                       ItemSize="20"
                                       HorizontalOptions="Center">
                    <rating:SfRating.RatingSettings>
                        <rating:SfRatingSettings RatedFill="Gold" UnRatedFill="White" RatedStroke="Black" UnRatedStroke="Black" />
                    </rating:SfRating.RatingSettings>
                </rating:SfRating>
                <Button Text="Todas as avaliações" TextColor="Black" FontSize="Small" HorizontalOptions="Center"/>
            </StackLayout>


Luis Alfredo Stockler Filho
Replied On May 15, 2017 10:59 AM

This is the screenshot from this code...
You see the SfRating alignment is aways left...

            <StackLayout Orientation="Vertical">
                <rating:SfRating       ItemCount="5"
                                       Value="3.6"
                                       Precision="Exact"
                                       TooltipPlacement="None"
                                       ItemSize="20"
                                       HorizontalOptions="Center">
                    <rating:SfRating.RatingSettings>
                        <rating:SfRatingSettings RatedFill="Gold" UnRatedFill="White" RatedStroke="Black" UnRatedStroke="Black" />
                    </rating:SfRating.RatingSettings>
                </rating:SfRating>
                <Button Text="Todas as avaliações" TextColor="Black" FontSize="Small" HorizontalOptions="Center"/>
            </StackLayout>


Attachment: Screenshot_20170515114132_650d02e7.rar

Rathana Kumar Sekar [Syncfusion]
Replied On May 16, 2017 07:27 AM

Hi Luis,

Thanks for your update.

In our current implementation, there is no support for SfRating control autosizing. Due to this, it is needed to manually set the WidthRequest of the control based on the item size we set. We have already logged feature report for "SfRating autosizing" and it will be available our upcoming Vol 2 SP 1 release and which will be rolled out by the end of this month.

We have created a sample based on your requirement by providing WidthRequest to the control. Please find the sample from the below link.

Sample: http://www.syncfusion.com/downloads/support/forum/130466/ze/RatingItemspacing-1968891897

Regards,
Rathanakumar S.

Luis Alfredo Stockler Filho
Replied On May 17, 2017 05:27 PM

Thank Rathana for your answer.

I've tested here and it is working now... a little bit awkard but it's working...

Thank you again for your fast and precise answers.

Luis Alfredo

Rathana Kumar Sekar [Syncfusion]
Replied On May 18, 2017 05:39 AM

Hi Luis,

Thanks for your update.

We are glad to know given solution helps you.

Please let us know if you have any other query.

Regards,
Rathanakumar S.


CONFIRMATION

This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.

;