Prithniraj Nicyone Prithniraj Nicyone - 11 months ago 66
Android Question

SetError with setFocusable(false) in android

I am having an edittext and an icon. Clicking on this icon I show DateTime Picker. I have set

and using setError on this edittext. But when any error occurs only icon is getting shown. Text is not getting shown at all. I have tried
also but it gives users to enter any text in this edittext which I do not want as I have created this edittext for date time only.

So, how can I show the error message then, can someone please help me.

Thanks a lot in advanced.

Answer Source

Why do you use an edittext, if you do not want the user to input text? you can use a textView and textView.setText("your time") instead.