Search code examples
androidandroid-edittext

Make EditText ReadOnly


I want to make a read-only EditText view. The XML to do this code seems to be android:editable="false", but I want to do this in code.

How can I do this?


Solution

  • Please use this code..

    Edittext.setEnabled(false);