Thunkable X - playing music (ie a theme song) while using the app

Okay, I have a couple of posts, as I am trying to get comfortable with thunkable x. I have searched the community and not found anything specific to these issues.

This one is about music. I added a song to my app that I want to play while user is accessing the app.

It works fine except:

When I close (ie minimize, like to go to another app, browser, etc.), the music keeps playing. It also starts to ‘double up’ , as in the song plays over itself as I leave/enter the app.

I am using ‘onsourceloaded’ function to call the song to play.

Ideally, I would like a song to play continually while user is enjoying the app, looping. And, it should pause or start over when a user leaves the app and start again when user returns to the app. (Most apps/games have such a theme song that plays in the background while user is playing)

Anyone have any success with such an endeavor? Appreciate any input.


1 Like

Just to add info regarding my issue with sound in my project: when I access the app on my IPad, the sound DOES stop when I leave the app to go to another program.

However the sound will not stop when I leave the app using my android phone. But when I receive a phone call on my android phone and have left the app, the sound will stop then.

Naturally I want the theme song of the app to only play when I am accessing the app. Anyone else have this issue, or know how to ensure the sound only plays when I am using the app? Note I am using an mp3 file with the sound component, using the “When onsourceloaded” function.

Please advise if anyone has had this issue and/or can advise a solution.

Thank you!

Hi Roger,
We are getting the same behaviour as you are describing.
Can you please share with me if you got a solution for this?
Many thanks in advance.
Regards, Mirian

Is it really a sensible thing to ask someone for a solution 2 years after they last posted in this topic?

Create a new topic, explain what should be happening, and what happens instead. Show your blocks. Then maybe you’ll get an answer.

1 Like