I applied UICollectionView in my application. My problem is that I need to select (for example, if the user clicked on it) a cell programmatically . Method:
- (void)selectItemAtIndexPath:(NSIndexPath *)indexPath animated:(BOOL)animated scrollPosition:(UICollectionViewScrollPosition)scrollPosition
This is part of the UICollectionView class - this is not what I need to call, since this method does not call:
- (void)collectionView:(UICollectionView *)collectionView didSelectItemAtIndexPath:(NSIndexPath *)indexPath
It simply sets the selected property of the cell to YES ;
source share