How can I format a users text field input as they type and insert a "-" or " " on every 5th character.
4500000000000000 becomes 4500 0000 0000 0000
How can I format a users text field input as they type and insert a "-" or " " on every 5th character.
4500000000000000 becomes 4500 0000 0000 0000
Make a delegate for your text field, then implement -textField:shouldChangeCharactersInRange:replacementString:
to update the text field whenever the user types / pastes anything.