jeudi 15 octobre 2015

How do I use SQLite in android?

I've founde already a few answers to this topic (for example this), but it is not working. I only get the warning, that it cannot resolve the method 'openOrCreateDatabase(java.lang.String, int, null)'.

Here is my sourcecode:

public class DBHandler
{
    SQLiteDatabase database;
    DBHandler()
    {
        database = openOrCreateDatabase("DatabaseName", Context.MODE_PRIVATE, null);
    }
}

Aucun commentaire:

Enregistrer un commentaire