开发者

Scroll the entire page with with UITableView that doesn't take up the entire screen

开发者 https://www.devze.com 2023-01-02 06:14 出处:网络
The only UITableViews I have worked with thus far are sized to fill the entire page. I\'m trying to create a page in my app where I will have an image and a label on the top of the page followed by a

The only UITableViews I have worked with thus far are sized to fill the entire page.

I'm trying to create a page in my app where I will have an image and a label on the top of the page followed by a UITableView to hold comments below it.

Something like this springs to mind: http://www.inquisitr.com/wp-content/fbb.jpg

My problem is if I add a 开发者_运维问答UITableView below the image and label, when I scroll the tableview then only the UITableView cells scroll. Not the entire page.

How would I go about making the entire page scroll so that the label and image scroll off the page and more table cells appear?

Thanks.


Put your image and label in a container UIView, and then set that container to the tableHeaderView property of your UITableView.


You could try setting the tableHeaderView property of the UITableView to a custom view containing your controls.

0

精彩评论

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