dimanche 1 février 2015

Android SQLite Query DB field against a Texfield value ?

I'm currently coding my login activity. I want to test to see if the username the user has entered is in the database. So far i have...



EditText email = (EditText) findViewById(R.id.tf_email);
EditText pass = (EditText) findViewById(R.id.tf_password);

String username = email.getText().toString();
String password = pass.getText().toString();

DBAdapter db = new DBAdapter(this);

db.open();
Cursor u = db.getAllUsers();
if (username = .....)


Thank you in advance.


Aucun commentaire:

Enregistrer un commentaire