Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
名前専用のUITextFieldを作成しようとしていますが、文字のみに制限する方法がわかりません。数字だけが可能だと知っていますが、文字だけが可能なのはどうしてですか?
デリゲートを使用して実装します。
- (BOOL)textField:(UITextField *)textField shouldChangeCharactersInRange:(NSRange)range replacementString:(NSString *)string
ここで置換文字列を検証します。