經過實踐,要是把下面三個協議方法都實現了就不會報錯了。另外還須要注意!的問題。spa
func tableView(tableView: UITableView, numberOfRowsInSection section: Int) -> Int{
}
func tableView(tableView: UITableView, cellForRowAtIndexPath indexPath: NSIndexPath) -> UITableViewCell{
}
func tableView(tableView: UITableView, didSelectRowAtIndexPath indexPath: NSIndexPath){
orm
tableView.deselectRowAtIndexPath(indexPath, animated: true)it
} io