Going to another app after starting a song in Spotify

Dear Community,

I want to create a process where my web browser (or any other app but to keep it simple let’s use web browser for now) opens after I started a song in Spotify from my app.

I managed two scenarios.

a) When I use “ActivityStarter1” with Action “android.intent.action.MAIN” I could manage to start the web browser using a timer and a second ActivityStarter. BUT in this case the song does not play. Spotify just opens and after 3 sec(duration of timer) the web browser opens.

b) When I use “ActivityStarter1” with Action “android.intent.action.VIEW” I could manage to start playing the song in Spotify. BUT in this case I got “stucked” in Spotify and the web browser does not open anymore.

So since both targets (starting a song in Spotify & going afterwards to web browser) where achieved separately from each other I was now wondering if there is any method to combine them.

Thanks for your help and support.

Yes, after starting another app, your own app is not active anymore. As possible solution before starting Spotify you could try my alarmmanager extension to autostart your app after a few seconds again, more info see here App Inventor Extensions: Alarm Manager | Pura Vida Apps
I currently do not know, if the song keeps playing though... something to be tested...

Taifun