Search code examples
objective-cuiscrollviewxcode4.2uitextviewuialertview

programmatically implement UIScrollView in a UIAlertView


I would like to programmatically Add a UIScrollView in a UIAlertView.

I found a way to do that but I was not successful in adding text to this UIScrollView (using the same code as in here: https://www.youtube.com/watch?v=4SG0CAAl5u0).

is there an alternative to do that? the text I have is very long and I need people to be able to scroll but without being able to edit it.

I know that the Apple user interface guideline does not recommend long text in alerts (although detecting WiFi networks does that) but I have no choice but doing it


Solution

  • If you add a large text in UIAlertView it automatically becomes scrollable. You don't have to do any thing to make it scrollable.