https://github.com/jgilfelt/android-sqlite-asset-helper
I\'m switching from SQLiteOpenHelper
to SQLiteAssetHelper
so i can use an existing DB s
Do not initialize Activity instance variables that require a Context in their declarations, as the Context will be null. Initialize dbTools
inside an appropriate lifecycle method like onCreate
:
DbHelper dbTools;
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
...
dbTools = new DbHelper(this);
}