sqlite error “Cannot open file” in phonegap Sample

1,026 views
Skip to first unread message

Ian

unread,
Apr 10, 2011, 4:21:27 PM4/10/11
to phonegap
The Phonegap sample project for Android crashes on startup when I try
to run it on an Android 2.2 emulator:

I/System.out( 279): loadUrl(file:///android_asset/www/index.html)
I/System.out( 279): url=file:///android_asset/www/index.html
baseUrl=file:///android_asset/www
I/ActivityManager( 59): Displayed activity
com.phonegap.Sample/.Sample: 2369 ms (total 35992 ms)
I/ActivityManager( 59): Displayed activity com.android.launcher/
com.android.launcher2.Launcher: 35996 ms (total 35996 ms)
I/Database( 279): sqlite returned: error code = 14, msg = cannot open
file at source line 25467

I've verified that the WRITE_EXTERNAL_STORAGE permission is in
AndroidManifest, and I've confirmed that sqlite databases do in fact
exist in /data/data/com.phonegap.Sample/databases/.

What are potential causes of this sqlite error?

(The problem is the same even if I take the latest jar and js file
from github)

Ian

unread,
Apr 10, 2011, 8:09:44 PM4/10/11
to phonegap
The error does not occur if I comment out the portion of phonegap.js
that initializes geolocation using addConstructor.

Simon MacDonald

unread,
Apr 11, 2011, 2:59:58 PM4/11/11
to phon...@googlegroups.com
You can safely ignore this error:

I/Database(  279): sqlite returned: error code = 14, msg = cannot open file at source line 25467

I've seen that error since day one and never run into any problems.

The Geolocation constructor should detect that you are using the built in geolocation code since you are running Android 2.2.  All Android devices of 2.X have geolocation built into the web browser.

Is there more information in "adb logcat" that may point out the root cause of the problem?

Simon Mac Donald
http://hi.im/simonmacdonald


--
You received this message because you are subscribed to the Google
Groups "phonegap" group.
To post to this group, send email to phon...@googlegroups.com
To unsubscribe from this group, send email to
phonegap+u...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/phonegap?hl=en?hl=en

For more info on PhoneGap or to download the code go to www.phonegap.com

Reply all
Reply to author
Forward
0 new messages