UICollectionView - Scrolling to first cell

后端 未结 8 1590
一生所求
一生所求 2021-02-12 18:00

I\'m making use of UICollectionView and I need to scroll to first cell after click in a button.

The button is located in a (big) header section in my collection view...

8条回答
  •  醉话见心
    2021-02-12 18:17

    It might be possible to use the UIScrollView related property

    collectionView.contentOffset.x = 0
    

提交回复
热议问题