Quantcast
Channel: Recent Threads — Xamarin Community Forums
Viewing all articles
Browse latest Browse all 204402

CollectionView Horizontal Cards has some event like SelectedIndex, OnSwipe etc

$
0
0

Hi Guys,

I start use XF4 with CollectionView, but i need put a page dots in my layout.

I not found how can i do that. :bawling:

I Create a custom render to remove horizontal bar, it work.
but how can i create a custom event like ScrollAnimationEnded, Scrolled to take a first visible index in Android and iOs.

My CustomRender to remove horizontal scroll indicator :

public class CustomCollectionView : CollectionViewRenderer
    {
        protected override void OnElementChanged(ElementChangedEventArgs<ItemsView> e)
        {
            base.OnElementChanged(e);

            if (Control != null)
            {
                NSArray s = Control.ValueForKey(new NSString("_subviewCache")) as NSMutableArray;
                UICollectionView c = s.GetItem<UICollectionView>(0);
                c.ShowsHorizontalScrollIndicator = false;   // this line


            }
        }
    }

tks


Viewing all articles
Browse latest Browse all 204402

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>