开发者

Why numberOfSectionsInTableView is called twice in UITableViewController?

开发者 https://www.devze.com 2023-04-07 08:44 出处:网络
Is there any other reason (than calling \"reloadData\") why numberOfSectionsInTableView is called twice? I did debugging and found, that it\'s get called twice during initial startup when no custom re

Is there any other reason (than calling "reloadData") why numberOfSectionsInTableView is called twice? I did debugging and found, that it's get called twice during initial startup when no custom reloadData statements are called.

开发者_如何学编程

I have created the table with IB but does that might cause a problem?


Have a look at the call stack. you can see that this method is being called from two different scenarios.


Probably your tableView object may instantiate twice. Once i have encountered the same problem due to this.

0

精彩评论

暂无评论...
验证码 换一张
取 消