How could we validate that given string should only contains alphabetic characters,
pls share some ideas,
thanks in advance
Jump to Post
- use the String matches(Regex) method with a regular expression for whatever you consider to be a letter in whatever languages you need to support.
- check each char in the String one at a time using Character's isLetter(char) method which knows about non-english characters.
All 3 RepliesReply to this topic
Be a part of the DaniWeb community
We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.