PDA

View Full Version : Toggling the Background Music On and Off


Adam
12-14-2007, 01:09 PM
It is possible in AutoPlay Media Studio to have music playing in the background of your application.

To allow the user to turn off this music if they wish:

1. Create a button.
2. On this button's On Click event, insert the following code:
Audio.TogglePlay(CHANNEL_BACKGROUND);

This example assumes the background music in your application is playing in channel CHANNEL_BACKGROUND. When the user clicks the button, the background music will pause if it was playing, and play if it was paused.