1

它说

UIAlertView 没有可见的@interface 清除选择器'initWithTtile:message....

这就是我所拥有的-

UIAlertView *alert = [[UIAlertView alloc] initWithTitle:@"Error" message:[NSString stringWithFormat:@"Error %@, here is your error", [error description]] delegate: nil cancelbuttonTitle:@"Cancel" otherButtonTitles:nil, nil];
4

3 回答 3

6

问题在于cancelbuttonTitle B应该大写。喜欢cancelButtonTitle

UIAlertView *alert = [[UIAlertView alloc] initWithTitle:@"Error" message:[NSString stringWithFormat:@"Error %@, here is your error", [error description]] delegate: nil cancelButtonTitle:@"Cancel" otherButtonTitles:nil, nil];
于 2013-06-13T06:19:10.457 回答
-1

说明因为方法不对

利用

  UIAlertView *alert = [[UIAlertView alloc]initWithTitle:@"Error"
                          message:[NSString stringWithFormat:@"Error %@, here is your error", [error description]]
                          delegate:self
                          cancelButtonTitle:@"Cancel"
                          otherButtonTitles:nil, nil];
于 2013-06-13T06:11:43.533 回答
-1

initWithTtle 写在您的错误中-应该是Title而不是 Ttle

于 2013-06-13T06:12:32.050 回答