我是Xcode的新手,我需要知道如何使用我添加到表格中的Detail Disclosure按钮.按下圆形蓝色箭头按钮会将用户重定向到另一个ViewController,在该ViewController中,将显示所选行中的数据.我将把它用于更新目的.我为我缺乏iOS编程知识而道歉.请耐心等待我.谢谢!:)
如何在alertview中添加文本字段?我正在尝试做一个应用程序,在应用程序提交编辑之前,用户必须通过在所述alertview上键入他/她的密码来验证第一,但我该怎么做?似乎我搜索的代码不再起作用了.这里是:
UIAlertView *alert = [[UIAlertView alloc] initWithTitle:@"Log In" message:@"Please enter your Password" delegate:self cancelButtonTitle:@"Log In" otherButtonTitles:@"Cancel", nil];
[alert addTextFieldWithValue:@"" label:@"Password"];
UITextField *tf = [alert textFieldAtIndex:0];
tf.clearButtonMode = UITextFieldViewModeWhileEditing;
tf.keyboardType = UIKeyboardTypeAlphabet;
tf.keyboardAppearance = UIKeyboardAppearanceAlert;
tf.autocapitalizationType = UITextAutocapitalizationTypeWords;
tf.autocapitalizationType = UITextAutocorrectionTypeNo;
Run Code Online (Sandbox Code Playgroud)
错误说
"No visible @interface for 'UIAlertView'
declares the selector 'addTextFieldWithValue:label:'"
on the [alert addTextFieldWithValue:@"" label:@"Password"];
Run Code Online (Sandbox Code Playgroud)
我还想问一下如何将代码放在alertview上的Confirm按钮上.