Monday, April 30, 2012

Creating an Android Service with Phonegap? (Have phonegap app run even when closed)

I have been working on an Android app using Phonegap and now would like to make it so when the app is closed it can still execute the java/js code in the app. So I understand I need to create a service. If I create a service plugin on phonegap can I still execute the javascript code or only the java?



Has anyone does something like this? I found this discussion but did not seem to work: http://groups.google.com/group/phonegap/browse_thread/thread/722b0e796baa7fc6
So that is all I have right now.



Before I turn to developing it native if I can't figure it out thought I would ask if anyone has done this before. I can't seem to find any of the phonegap plugins that do something similar.



EDIT: I have got an app that executes Java code as a service. However when it calls sendjavascript it does not work. So is there a way to have the javascript code running in the background as well when an app is closed with phonegap?



Thanks





No comments:

Post a Comment