This should be simple. I'm making a very basic app, based on the Utility Application template of XCode. On the flipside, I have more content than fits the screen. The flipside is a UIView. I think it should be a UIScrollView, but somehow I don't get it to work. Can anybody here advise me on this?
A:
With a UIScrollView it is not enough just to place the control into Interface Builder and place the items within it; you have to set its content size in code.
Therefore in the -viewWillAppear
method (or similar) you should have something like:
[scrollView setContentSize:CGSizeMake(320, 600];
This would make the content size inside the scroll view 600 pixels high (ie larger than the height of your iPhone display). If everything else is wired up correctly, this shoud now work.
Note: You may also then need to reposition your objects within the view. Set frame.origin
for the objects that require this...
h4xxr
2010-05-26 09:59:08