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?