开发者

iphone--how to use checkmark to filter the information?

I know how to add checkmark into the tableview, but the question is how to use checkmark to filter the information? That means if i have checked item-1开发者_StackOverflow, in the table view or view just display the related information about item-1. Anyone can help me or tell me some related tutorial~ Thanks


Here's one approach:

  • Register an action for your checkmark (not sure how you've implemented it but if it's, say, a UIButton, use the addTarget method)

  • In the method that gets called when you click the checkmark, modify the data source so that it's filtered to what you want to display

  • Call [self.tableView reloadData] to have the UITableViewController reload its tableView object

Hope this helps!

0

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜