Skip to content
Advertisement

Android java : Error on SQLiteDatabase db = this.getWritableDatabase();

Am a beginner at android java.

Error on SQLiteDatabase db = this.getWritableDatabase(); line in

JavaScript

ERROR :

JavaScript

I already had called the getWritabledatabase in the insert function. But when I try to write again. It doesn’t work.

Advertisement

Answer

You need to pass a valid Context to your SQLiteOpenHelper constructor.

User contributions licensed under: CC BY-SA
5 People found this is helpful
Advertisement