Hello:
I refer to the :Tizen IDE,help content.
Tizen Mobile Native App Programming > Tutorials > Application Framework Tutorials->Data Control Tutorial
Using the SQL-type Data controls. I copy the code ,and start it in the app_create():
static bool app_create(void *data) { appdata_s *ad = data; create_base_gui(ad); initialize_datacontrol_provider(); initialize_datacontrol_consumer(ad); return true; }
but I come to an Error:
//////Register the callback and create the database int create_database() { dlog_print(DLOG_INFO, LOG_TAG, "%s%s", app_get_data_path(), "mytest.db"); int open_flags = (SQLITE_OPEN_READWRITE | SQLITE_OPEN_CREATE); char* text = app_get_data_path(); int ret = sqlite3_open_v2(app_get_data_path() , &db, open_flags, NULL); if (ret != SQLITE_OK) { dlog_print(DLOG_ERROR, LOG_TAG, "database creation failed with error: %d",ret); dlog_print(DLOG_ERROR, LOG_TAG,"Fatal error: %s",sqlite3_errmsg(&db)); return ret; }
as the bold above ,
int ret = sqlite3_open_v2(app_get_data_path() , &db, open_flags, NULL);
when I debug, the ret == 14.
I print the errmsg by sqlite3_errmsg(&db), It says:
library routine called out of sequence.
Please Help!