The sound is not muted with the click event of the button

In this activity, it is expected that the sound introducing the “mouth” will play when the “+ button” is pressed, and that the sound will not play along with the page when the “X button” is pressed.
There is a “play audio” command to add sound, but there is no command to mute sound.
How can I solve this problem? Can you help me?

1 Like

Hi @cemileyavuz,

Please take a look at the sample I created below:

To achieve what you need, instead of using the Play Audio action, please use the Show/ Hide Audio Object as you can see in the Interactivity tab:

So, you will add audio objects to the canvas first. If you do not want the audio objects to appear on the canvas, drag them outside the white canvas like this:

In the Properties pane of the audio, remember to check Autoplay.

Then, after creating the information pop-up, you will set the audio object and this pop-up to be Initially Hidden (right-click and choose).

Then, add events & actions to the button as in the image so that when you click that button, the pop-up will appear and the audio object will appear, too. As you have checked the Autoplay option, when the audio object appears, the audio is autoplayed.

Finally, add events & actions to the Close button as in the image so that when you click Close, the pop-up will disappear, and the audio object will disappear as well. When the audio object disappears, there will be no sound playing anymore.

Hope the information clarifies.

Quynh Anh

1 Like