我选择了单元格但代码不起作用时,我已按程序设置了按钮标题
这是代码
func tableView(tableView: UITableView, didSelectRowAtIndexPath indexPath: NSIndexPath) {
if indexPath.row == 0
{
btnLocation.setTitle("Your Location", forState: UIControlState.Normal)
}
else
{
btnLocation.setTitle(locArr[indexPath.row - 1], forState: UIControlState.Normal)
}
//location = locArr[indexPath.row]
print(locArr[indexPath.row])
table1.deselectRowAtIndexPath(indexPath, animated: true)
table1.hidden = true
flag = 0
}
我不知道如何解决它!!!!!
由于