Eliminate the scrolling effect

Eduardo Gomez 3,416 Reputation points
2022-01-24T02:10:49.11+00:00

Hello

In this case, I don't know if I should use a collectionView.

I want to maintain this UI, where I have two columns of avatars, but I think is ugly to maintained the scrolling effect. I already tried a bindable layout, but I can fit all of them

167601-screenshot-2022-01-24-030303.png

ProfilePage

So how can I maintain this, without the scrolling effect

Project

https://github.com/eduardoagr/DuoNotes

Xamarin
Xamarin
A Microsoft open-source app platform for building Android and iOS apps with .NET and C#.
5,294 questions
0 comments No comments
{count} votes

Accepted answer
  1. Leon Lu (Shanghai Wicresoft Co,.Ltd.) 68,571 Reputation points Microsoft Vendor
    2022-01-24T02:54:20.827+00:00

    Hello,​

    Welcome to our Microsoft Q&A platform!

    You can disable the Scrolling effect by collectionview's custom renderer. There are not many profile images , you can use ScrollView as well. But ScollView have this scrolling effect as well, you also need to disable it.

       [assembly: ExportRenderer(typeof(CollectionView), typeof(NativeAndroidCollectionViewRenderer))]  
       namespace DuoNotes.Droid  
       {  
           internal class NativeAndroidCollectionViewRenderer : CollectionViewRenderer  
           {  
               public NativeAndroidCollectionViewRenderer(Context context) : base(context)  
               {  
               }  
               
         
               protected override void OnElementChanged(ElementChangedEventArgs<ItemsView> elementChangedEvent)  
               {  
                   base.OnElementChanged(elementChangedEvent);  
                   if (elementChangedEvent.NewElement != null)  
                   {  
                       this.OverScrollMode = OverScrollMode.Never;  
                   }  
               }  
           }  
       }  
    

    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.


0 additional answers

Sort by: Most helpful