Advertisement
Guest User

Untitled

a guest
Jul 28th, 2017
62
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.64 KB | None | 0 0
  1. -(NSInteger) numberOfSectionsInCollectionView:(UICollectionView *)collectionView{
  2. return 1;
  3. }
  4.  
  5. -(NSInteger)collectionView:(UICollectionView *)collectionView numberOfItemsInSection:(NSInteger)section{
  6. return arrNames.count;
  7. }
  8.  
  9. -(UICollectionViewCell *)collectionView:(UICollectionView *)collectionView cellForItemAtIndexPath:(NSIndexPath *)indexPath{
  10. UICollectionViewCell *cell = [collectionView dequeueReusableCellWithReuseIdentifier:@"areacell" forIndexPath:indexPath];
  11.  
  12.  
  13. UILabel *lblName = (UILabel *)[cell viewWithTag:101]; // set tag in storyboard for this label
  14. lblName.text = arrNames[indexPath.item];
  15.  
  16. return cell;
  17. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement