How to make the drawableright image on textview to appear and disappear programmatically in android. I have a textview and a button. When user press the button, it suppose to use the data on the textview to do something. However, if textview is empty, I want to show an error icon on the drawableright. Please advise.
Asked
Active
Viewed 459 times
1 Answers
1
I think you are looking for http://developer.android.com/reference/android/widget/TextView.html#setError(java.lang.CharSequence)
Basically it will show a default error icon on the right inside the textview if you set it.

WenChao
- 3,586
- 6
- 32
- 46