Droidand
Droidand

Reputation: 176

Android Special Characters

Hi i need to validate an edit text box which user need to enter his height, I need to allow the user only this two symbols (" ') ex: 5'11". I want to restrict user entering other special characters, how to restrict, need a help

Upvotes: 0

Views: 1446

Answers (1)

ingsaurabh
ingsaurabh

Reputation: 15269

Set following property to your edittext

android:digits="'"1234567890"

Upvotes: 2

Related Questions