UIScrollView bad contentSize height when in Landscape (ipad)

2.7k Views Asked by At

I've a problem using a UIScrollView with subviews and vertical scrolling.

When in portrait mode it scrolls fine, but when in landscape, even if I set an arbitrary value (let's say 1400px), it doesn't really scroll along that size, removing around 400 pixels and it stops before the content is fully visible.

Any ideas?

1

There are 1 best solutions below

0
On BEST ANSWER

Did you try to set

yourScrollView.autoresizingMask = UIViewAutoresizingFlexibleWidth | UIViewAutoresizingFlexibleHeight;

It should resize the scrollview height.