brettfazio
brettfazio

Reputation: 1156

Move everything in a Storyboard view into a scroll view

I have a view (show below) in my storyboard. When I am typing in the stuff on the bottom the keyboard covers up what I am typing. The easiest way (I believe) to solve this would be to put everything in the view in a UIScrollView.

Is there an easy way to move everything in that view into a scroll view? Or if you believe there is a better way to do this what is it?

enter image description here

Upvotes: 5

Views: 1328

Answers (2)

brettfazio
brettfazio

Reputation: 1156

To solve this issue I did something slightly similar to @paulvs to move all of the text fields into the scroll view first I made a new view controller and put a scroll view in it. Then I selected all of the text fields using command on the keyboard and copy-pasted them into the scroll view.

Not sure if this is the most elegant way to make sure the user can see the text boxes at the bottom but it seems to have worked to move the text fields.

Upvotes: 2

Ajay Kumar
Ajay Kumar

Reputation: 1827

For putting everything in scrollview just select all your views (hold shift and click on every view) and go to editor in toolbar of xcode select option 'Embed In', select scroll view and you are done.

Upvotes: 7

Related Questions