How do I make a music play when opened another screen?

hi,
i have a coding problem, i want to when opened from 1 screen to another screen a music will play at the screen that changed, can anyone help me?

See also here: How to ask a question (open new topic)

Just like this:

also, make sure to stop the player when switching screens