Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- -(NSInteger) numberOfSectionsInCollectionView:(UICollectionView *)collectionView{
- return 1;
- }
- -(NSInteger)collectionView:(UICollectionView *)collectionView numberOfItemsInSection:(NSInteger)section{
- return arrNames.count;
- }
- -(UICollectionViewCell *)collectionView:(UICollectionView *)collectionView cellForItemAtIndexPath:(NSIndexPath *)indexPath{
- UICollectionViewCell *cell = [collectionView dequeueReusableCellWithReuseIdentifier:@"areacell" forIndexPath:indexPath];
- UILabel *lblName = (UILabel *)[cell viewWithTag:101]; // set tag in storyboard for this label
- lblName.text = arrNames[indexPath.item];
- return cell;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement