In my project need to add uiview in UITableViewCell. I can add UIView using following code in UITableViewCell class.
-(void)drawRect{
[cell.contentView addSubview:myView];
}
Is this a efficient way to show when large amount of table cell are displaying. Is there other way to add UIView using method like.
drawInRect
You will want to add the subView in the
- (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath
which is part ofUITableViewDataSource
protocol.