Finish another App service

Asked

Viewed 59 times

0

The thing is, I’ll have two apps running on a client’s phone, one of them just starts a few services and the other does some operations, the problem is I can’t unify the two, it’s a long story, now I wonder how to interrupt the service of the first application from the second, just changing a variable(EX: servicoAtivo), this is possible?

  • Gabriel, did you ever check if just calling the Context.stopService(android.content.Intent) passing a Intent to the Service that you want to stop? In case you are giving permission error, you can try to put the two applications to share the same user and process and run the stopService normally. Take a look at this question for help: http://stackoverflow.com/questions/17664090/can-multiple-android-applications-share-a-single-process-and-application-context.

  • Hi thanks guy, I found the solution, I created a function in the other app that as soon as called set a variable that ended the service, I will post the solution

1 answer

0

Browser other questions tagged

You are not signed in. Login or sign up in order to post.