How to detect removal of ios IP address

Does anyone know how to detect the removal from the numeric keypad in ios?

+3
source share
2 answers

If you use UITextField, your delegate textField:shouldChangeCharactersInRange:replacementString:will be called with a range of length 1 and an empty replacement. However, if nothing is deleted, you will not receive a notification.

If you use a UITextView, your delegate textView:shouldChangeTextInRange:replacementText:will be called with a range of length 1 and an empty replacement. However, if nothing is deleted, you will not receive a notification.

, UIKeyInput, , deleteBackward. , , UITextInput ( UIKeyInput), replaceRange:withText: setMarkedText:selectedRange: 1 , .

+4

- , , .

0

All Articles