2014-11-01 115 views
1

我在選擇tableView中的一行時遇到問題,問題是當我第一次選擇一行時,它會用灰色突出顯示,但沒有任何反應,我必須再次選擇一個行執行「didSelectRowAtIndexPath方法」,並帶我到其他的ViewControllerTable didSelect方法無法正常工作

-(void)tableView:(UITableView *)tableView didDeselectRowAtIndexPath:(NSIndexPath *)indexPath{ 
    //Data 
    NSLog(@"row selected %d", (int)indexPath.row); 

} 

回答

3

不幸的是你保持didDeselectRowAtIndexPath,更換didSelectRowAtIndexPath

+0

謝謝晴天 – user3363841 2014-11-01 12:36:49

+0

你救了我的一天^^我做了同樣的錯誤:p – Atomnium 2014-12-02 16:38:55