I'm trying to check an EditText value, but the application crashes.
How can I handle my EditText?
String stra_txt = edit_1.getText().toString();
boolean first = false;
if (stra_txt.equals("1") || stra_txt.equals("0"))
{
first = true;
}
else
{
first = false;
}
if(first = true)
zheg();
else
{System.exit(0);}
this code does not work too:
String stra_txt = edit_1.getText().toString();
if (stra_txt.equals("1") || stra_txt.equals("0"))
{
zheg();
}
else
{
System.exit(0);
}
Aucun commentaire:
Enregistrer un commentaire