How to add buttons in alertView in different lines?

121 Views Asked by At

I want to create an alertView that shows 2 buttons- Delete Photo and Cancel. I want the buttons to appear in different lines. But whenever I try, I get them in the same line.

1

There are 1 best solutions below

0
Rashad On BEST ANSWER

There is no SDK support for this. Button will appear in one per line if you have more than two button. But for two button it will be in one line.

But its possible by subclassing UIAlertView. But apple says:

The UIAlertView class is intended to be used as-is and does not support subclassing. The view hierarchy for this class is private and must not be modified.