4

I'm looking for a method to switch to the previously opened external app activity. I'm developing an app with a background service.

there are many apps that has this function already as this one (LAS)

getRecentTasks() is deprecated

I found also this answer however it returns the package, which when I try to launch opens the app from the start, not from the last opened activity. How can I do this?

Mo Dev
  • 475
  • 6
  • 17
  • There's really no way to do this. ANd if you launch it as an activity, you could be screwing things up (you're unlikely to have the same intent parameters). The best/only way to do this is to finish() all of your activites. Then the last activity before your app will be on top. – Gabe Sechan Sep 07 '19 at 06:48
  • Thanks but I'm asking about dealing with EXTERNAL apps through my service. NOT MY APP activities. – Mo Dev Sep 07 '19 at 11:10

0 Answers0