I want to present a modal view with a UIscrollView
as the content of the view. How would I do this?
Asked
Active
Viewed 778 times
0

Jab
- 26,853
- 21
- 75
- 114
2 Answers
1
Create a standard UIViewController, and give it a UIScrollView as its view member. Then use -[UIViewController presentModalViewController:animated:] on your current (visible) view controller. This will (by default) slide the new one in from the bottom.

Ben Gottlieb
- 85,404
- 22
- 176
- 172
1
As always, do a viewController and set it's view as the scroll view (in load view)
self.view = aScrollView;
and present it modally : (in your first viewController)
[self presentModalViewController:theViewController animated:YES];

gcamp
- 14,622
- 4
- 54
- 85
-
I want to know what you meant by aScrollView – Jab Jan 08 '10 at 02:00
-
1He means a scroll view. Code to create one: [[UIScrollView alloc] initWithFrame:CGRectMake(x, y, w, h)]; – Grant Paul Jan 08 '10 at 02:04