SQLiteOpenHelper problem

Posted by Harsha M V on Stack Overflow See other posts from Stack Overflow or by Harsha M V
Published on 2010-12-24T10:46:55Z Indexed on 2010/12/25 6:54 UTC
Read the original article Hit count: 160

Filed under:
|
|

I have created SQLiteOpenHelper class to help me open write the database. but i am not able to invoke it from the main.java activity

I have created an Class which extends the Database Helper which is stored at

/Messaging/src/com/v3/messaging/DatabaseHelper.java

Code: http://pastebin.com/Z5qp32xu

now i have this class called Main.java which will be the first activity on the launch of the application. But how can i make the DatabaseHelper.java run just to create the database but still be at the Main.java file.

The database should be created with the tables only when the db or the tables dont exist.

Main.java code: http://pastebin.com/LVFVuhA0

Now when i run the program. the database is not being created :(

I am trying to learn Android. So please excuse me if i forgot to tell something.

© Stack Overflow or respective owner

Related posts about android

Related posts about sqlite