[ZPAlertView showAlertTitle:@"编辑短信内容" andMsg:@"编辑短信内容" cancelButtonTitle:@"取消" otherButtonTitles:@"确定" andBlock:^(NSInteger index,id contxt){
if (index == 1) {///确定的tag 值
///做你想做的事
}
}];
ZPTextField *textField = [[ZPTextField alloc] initWithFrame:CGRectMake(50, 50, 200, 50)];
textField.NBregEx = REGEX_POWER_TELPHOONE_NUMBER;
[self.view addSubview:textField];
请把代码粘贴在这里
//展示 ADlertView
+ (ZPAlertView *) showAlertTitle:(NSString*)title andMsg:(NSString*)msg cancelButtonTitle:(NSString *)cancelButtonTitle otherButtonTitles:(NSString *)otherButtonTitles andBlock:(AlertViewBlock)block{
if (!_sharedADlertView) {
_sharedADlertView = [[ZPAlertView alloc] initWith:title andMsg:msg cancelButtonTitle:cancelButtonTitle otherButtonTitles:otherButtonTitles andBlock:block];
}
else{
[_sharedADlertView showAlertView:title andMsg:msg cancelButtonTitle:cancelButtonTitle otherButtonTitles:otherButtonTitles andBlock:block];
}
return _sharedADlertView;
}