Question

I have made apk for my sencha-touch project but getting this error when trying to access the phonebook contacts. Please look into the matter.

Was it helpful?

Solution 2

I just put my sencha touch build file inside the myproject>www file of my phonegap project and also linked the cordova.js file which was already there and ran cordova run android and now my application is accessing phonebook. (Don't forget to add plugin for contacts cordova plugin add org.apache.cordova.contacts)

OTHER TIPS

Does it work on iOS? If so, perhaps you have forgotten to add the correct permissions to your Manifest.xml.

Those two could be helpful:

<uses-permission android:name="android.permission.WRITE_CONTACTS" />
<uses-permission android:name="android.permission.READ_CONTACTS" />

But only add them if you need them, because the user will get prompted with all needed permissions before he'll be able to install the application.

Another hint:

sencha app build testing

If you use this command to build your app, your app.js won't get minified an you will get the exact line of your error when building it native. This way your error is easier to debug!

More information over here

Hope that helps

update cordova_plugins.xml from cordova CLI .. I also got the same problem.I wasted half day for this but at last I updated my phonegap android project then android/assets/www/cordova_plugins.xml becomes what ever plugins I installed (At first I created phoneGap android then add's plugins using cordova CLI ... in this procedure the cordova_plugins.xml is not populated with respective "CONTACTS" plugin)

I resolved the same issue by just uninstall and reinstall the cordova plugin and add cordova-plugin-contacts.
Then its working fine for me.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top