-----------------
监听文字有多长
- (BOOL)textField:(UITextField *)textField shouldChangeCharactersInRange:(NSRange)range replacementString:(NSString *)string
{
if ( _contentTF == textField) {
if (_contentTF.text.length > 8) {
return NO;
}
}
return YES;
}
时间: 2024-11-03 21:37:41