Skip to content

Instantly share code, notes, and snippets.

@inailuy
Last active December 12, 2015 01:48
Show Gist options
  • Save inailuy/4693280 to your computer and use it in GitHub Desktop.
Save inailuy/4693280 to your computer and use it in GitHub Desktop.
creating custom tableview cells
// Registering Cell eg: -viewDidLoad
[self.tableView registerNib:[UINib nibWithNibName:MY_CELL_IDENTIFIER bundle:[NSBundle mainBundle]]
forCellReuseIdentifier:MY_CELL_IDENTIFIER];
// -tableView: cellForRowAtIndexPath;
UITableViewCell *cell = [self.tableView dequeueReusableCellWithIdentifier:MY_CELL_IDENTIFIER];
// Creating a var with cell tag
UIImageView *imageView = (UIImageView *)[cell viewWithTag:IMAGEVIEW_TAG];
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment