0
votes

I have an app which shows two images housed within a UIScrollview. The scrollview is of size (320, 530), underneath it is an imageview size (320,38), this acts like a dock at the bottom of this screen, ( in fact it has to be there at the bottom of all screens in this app).

As it stand the scrollview works fine and the images switch from one to anothr when the user moves the scrollview.

The problem is, I need the scrollview height to go all the way down ( from 530 to 568), and end up behind the dock imageview, when I change its height and the height of images within it, it just stops scrolling.

Is this impossible in scrollviews? does it have to have all of its screen real estate as top view?

Any solutions for this?

Thanks.

Update : so I worked on the alpha and the image constraints, and the bottom imnage is located properly, still the scrolling is not functioning.this is the latest code with changes.

http://ge.tt/4LYJGWl/v/0?c

thanks.

1

1 Answers

1
votes

This is certainly possible. Add a full height scroll view to the controller's view, then add the small image view to the bottom. In the scene list at the left move that image view up so it's directly underneath the main view, which will make it a subview of that view rather than the scroll view (you'll then need to move the scroll view up above the image view so the image view will appear on top). You'll probably have to change some constraints to pin it to the bottom, and give it an alpha value less than 1 so the scroll view will show through.

enter image description here

After Edit

This is the screen shot of the scene from your updated code:

enter image description here

You only have one view that's directly under the main view, your scroll view. Compare that to my image.