質問
iPhoneアプリケーションでは、uialertViewにuialertViewの数の列を設定できます。まるでUialertViewに6つのボタンがあるかのように、2列と3行で表示するにはどうすればよいですか。誰かがやった場合、それがどのように行われるかを親切に共有してください。
任意のサンプルコードは追加のヘルプになります
解決
a UIAlertView
ただです UIView
. 。そのため、ボタンを手動で追加できます UIAlertView
2つの列構成で。例があります ここ それは追加を示しています UITextField
S、しかし、私はあなたがそれを適応させることができると確信しています。
に2つの多くのボタンがあることに注意してください UIAlertView
Appleのバックアップを取得するかもしれません;-)
他のヒント
私はこのようにやった
NSArray *subViewArray = Topicdialog.subviews;
float y = 60.0f;
for(int x=2;x<[subViewArray count];x += 2){
UIView *button = [subViewArray objectAtIndex:x];
CGRect frame = button.frame;
frame.size.width = 120.0f;
frame.size.height = 42.0f;
frame.origin.x = 20.0f;
frame.origin.y = y;
button.frame = frame;
UIView *button1 = [subViewArray objectAtIndex:x + 1];
frame = button1.frame;
frame.size.width = 120.0f;
frame.size.height = 42.0f;
frame.origin.x = 152.0f;
frame.origin.y = y;
button1.frame = frame;
y = y + 48.0f;
}
所属していません StackOverflow