This should be easy, but I\'m having trouble.
I have a static UITableView with a cell that I would like to remove programmatically if it\'s not needed.
I have a
Depending on how your table is supposed to work, in your data source you can implement tableView:numberOfRowsInSection:
to return 0 rows for the section based on your necessary logic.
Updated for your comment:
The section parameter will be populated by iOS when your implementation is called so all you need is a switch to handle the section that has the row you ant removed/hidden. Example below:
- (NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section {
switch(section) {
case 0: // first section of your table, change for your situation
return 0;
default:
return 0;
}
}