开发者

how to create label in the table header in iphone applications?

Hi all i have create a table 开发者_Go百科at run time while loading the page. How to create a label at run time and assign a text to the label in the table header section.

Thanks


Make your data source return the correct NSString in -(NSString *)tableView:(UITableView *)tableView titleForHeaderInSection:(NSInteger)section;.

If you have others requirements than just displaying text in the header, implement this table view delegate method :

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

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜