user330885
user330885

Reputation:

How can I present an UIPopoverController from an UITableViewCell?

- (void)tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath
{
    if (indexPath.row == 5)
    {
        [tableView deselectRowAtIndexPath:indexPath animated:YES];
        [enginesPopoverController presentPopoverFromRect:[tableView bounds] inView:self.view permittedArrowDirections:UIPopoverArrowDirectionAny animated:YES];
    }
}

Upvotes: 3

Views: 2935

Answers (1)

Renegade428
Renegade428

Reputation: 414

[popoverController presentPopoverFromRect:[tableView rectForRowAtIndexPath:indexPath] inView:[self view] permittedArrowDirections:UIPopoverArrowDirectionAny animated:YES];

Good Luck!

Upvotes: 14

Related Questions