【iOS】tableView:viewForHeaderInSection: 方法未调用


今天遇到这个问题,即重写的方法

- (UIView *)tableView:(UITableView *)tableView viewForHeaderInSection:(NSInteger)section

没有调用。

 

可能的原因:

1. 没有设置 delegate

2. 没有重写方法

- (CGFloat)tableView:(UITableView *)tableView heightForHeaderInSection:(NSInteger)section

 

虽然我的问题不是上述两个,但也记下。

 


免责声明!

本站转载的文章为个人学习借鉴使用,本站对版权不负任何法律责任。如果侵犯了您的隐私权益,请联系本站邮箱yoyou2525@163.com删除。



 
粤ICP备18138465号  © 2018-2025 CODEPRJ.COM