Stop Background audio while starting
I could make the application, to play the audio when it moves to the background, by adding the setting in info.plist file. But, when some other iOS application plays background audio, and when the current application comes to foreground, how to stop the background audio invoked by other application? Have a look at AVAudioSession class and AVAudioSession programming guide by Apple. This will hopefully steer you in the right direction. To stop background audio when your application starts set your audio session to a non-mixable category and mode then set active. If you don't configure an audio