I've created a view with a UIScrollView
, it has height 1000px. I've added a UITableView
to the view, plus other labels and buttons. When I launch it, everything is in its place except the table. Can anyone fix my problem?
I've tried:
table.hidden = NO;
and
[scrollView addSubview:table];
but nothing happened.
The documentation for UIScrollView
specifically says not to do this:
Important : You should not embed
UIWebView
orUITableView
objects inUIScrollView
objects. If you do so, unexpected behavior can result because touch events for the two objects can be mixed up and wrongly handled.
I would suggest adding the other views you intend to put into the scroll view into the table as a tableHeaderView
, tableFooterView
, or as custom cells.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.