[_yourTextField addTarget:self action:@selector(eventEditingChange:) forControlEvents:UIControlEventEditingChanged];

-(void)eventEditingChange:(UITextField *)sender {

    UITextRange *markRange = sender.markedTextRange;
int pos = [sender offsetFromPosition:markRange.start
toPosition:markRange.end];
int nLength = sender.text.length - pos;
if (nLength > && pos == )
sender.text = [sender.text substringToIndex:];
}
04-28 21:44