-3

I want to check length of entered number while entering the value in edittext. Also i want to check user can only able to enter 5 or 0 after decimal point.

Thanks

1 Answers1

0

You should use TextWatcher. Use this documentation.https://developer.android.com/reference/android/text/TextWatcher.html

Then in OnTextChanged you can check what the length of the edit text is. I don't know how to check if the decimal point ends with 0 or 5. Sorry about that. You should ask a separate question about that. Hope this helps.

an3
  • 568
  • 1
  • 6
  • 14