Android examples for android.text:Editable
Get string Value from Editable
import android.text.Editable; import android.widget.EditText; public class Main{ static public String stringValueFor(Editable editable) { char[] cs = new char[editable.length()]; editable.getChars(0, editable.length(), cs, 0); return new String(cs); }//from w ww. ja v a 2 s . c o m static public String stringValueFor(EditText editable) { return stringValueFor(editable.getText()); } }