I have a tableViewController, my data source work well, but i can't select a row programmatically.
I have tried:
class DocumentTableViewController: UITableViewController {
override func viewDidLoad() {
super.viewDidLoad()
tableView.selectRow(at: IndexPath(row: 0, section: 0), animated: true, scrollPosition: UITableViewScrollPosition(rawValue: 0)!)
}
}
when I run, the tableView selects nothing. How can I solve that ?