CarouselView Window bug asthmatically loop

Eduardo Gomez Romero 705 Reputation points
2024-09-05T10:25:03.8833333+00:00

I have a CarouselView, but on Windows in will loop, this doesn't happen on android

 <VerticalStackLayout>
     <Label
         Margin="20"
         HorizontalOptions="Center"
         Text="{Binding SelectedPin.Address}"
         VerticalOptions="Center" />
     <CarouselView
         IndicatorView="indicatorView"
         ItemsSource="{Binding SelectedPin.CstomPinImages}">
         <CarouselView.ItemTemplate>
             <DataTemplate>
                 <VerticalStackLayout>
                     <Border
                         HeightRequest="300"
                         HorizontalOptions="Center"
                         VerticalOptions="Center">
                         <VerticalStackLayout>
                             <Image
                                 Aspect="AspectFit"
                                 Source="{Binding .}" />
                         </VerticalStackLayout>
                     </Border>
                 </VerticalStackLayout>
             </DataTemplate>
         </CarouselView.ItemTemplate>
     </CarouselView>
     <IndicatorView
         x:Name="indicatorView"
         Margin="0,0,0,40"
         HorizontalOptions="Center"
         IndicatorColor="LightGray"
         IndicatorsShape="Square"
         SelectedIndicatorColor="DarkGray" />
 </VerticalStackLayout>

example

https://reccloud.com/u/lqp74mb

.NET MAUI
.NET MAUI
A Microsoft open-source framework for building native device applications spanning mobile, tablet, and desktop.
3,541 questions
0 comments No comments
{count} votes

1 answer

Sort by: Most helpful
  1. Leon Lu (Shanghai Wicresoft Co,.Ltd.) 76,001 Reputation points Microsoft Vendor
    2024-09-06T07:15:11.0766667+00:00

    Hello,

    Please set Loop="False" , this issue will disappear.

    I test it in the 8.0.80 and reproduce this issue when I click the Indicator in Windows platform, please report this issue in MAUI GitHub repo

    Best Regards,

    Leon Lu


    If the answer is the right solution, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment".

    Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.


Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.