Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Get location data after app is cleared from task manager. #8

Closed
nimishpatel19 opened this issue Aug 19, 2016 · 2 comments
Closed

Get location data after app is cleared from task manager. #8

nimishpatel19 opened this issue Aug 19, 2016 · 2 comments

Comments

@nimishpatel19
Copy link

I have integrated this in my app. I want to perform task in background when location meets specific latitude and longitude.
BackgroundGeolocation.on('location', (location) => { ToastAndroid.show("Location: latitude: " + location.latitude + " longitude: " + location.longitude, ToastAndroid.SHORT); });

I have tried to toast message here. But it is not working when my app is killed from task manager.

Guide me that how can I make it run in background.

@nimishpatel19
Copy link
Author

My configurations are:
stopOnTerminate: false, startOnBoot: true,

@mauron85
Copy link
Owner

mauron85 commented Sep 19, 2016

I'm afraid you cannot do this, because main thread is dead.

EDIT: You can send push notification from server, when location criteria are met. (options url/syncUrl must be used)

EDIT2: Or you can hack this plugin and add functionality directly to service code.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants