- (void) tableViewSelectionDidChange: (NSNotification *) notification { int row; row = [tableView selectedRow]; if (row == -1) { do stuff for the no-rows-selected case } else { do stuff for the selected row } } // tableViewSelectionDidChangeIf you have more than one tableview, the notification's object is the tableview that had the selection change.