0

UIStepperで表示するにはどうすればよいUIAlertViewですか? UIStepperまた、ポップアップに表示する他の方法を提案してください。

4

2 に答える 2

4

これを試してください..それがあなたを助けることを願っています

 UIStepper *stepper = [[UIStepper alloc] initWithFrame:CGRectMake(120, 20, 0, 0)];

    UIAlertView *alert =[[UIAlertView alloc]init];// you can set your frame according to ypur requirment
    [alert addSubview:stepper];
    [alert show];
于 2013-02-14T06:45:57.800 に答える
2

ビューを挿入するより良い方法はUIAlertView、それらをサブビューとして追加することです

以下を試してください

UIAlertView *alert = [[UIAlertView alloc]initWithTitle:nil message:@"\n\n" delegate:nil  cancelButtonTitle:@"OK" otherButtonTitles: nil];
    UIStepper* stepper = [[UIStepper alloc] init];
    stepper.frame = CGRectMake(12.0, 5.0, 100, 10);
    [alert addSubview:stepper];
    [alert show];
于 2013-02-14T06:47:49.073 に答える