Anyone know how to convert this code to B4A
// stop music player
AudioManager am = (AudioManager)context.getSystemService(Context.AUDIO_SERVICE);
am.requestAudioFocus(null,AudioManager.STREAM_MUSIC,AudioManager.AUDIOFOCUS_GAIN_TRANSIENT);
//resume music player
am.abandonAudioFocus(null);
I am trying to pause any music player that is installed on the users system.
Thanks
// stop music player
AudioManager am = (AudioManager)context.getSystemService(Context.AUDIO_SERVICE);
am.requestAudioFocus(null,AudioManager.STREAM_MUSIC,AudioManager.AUDIOFOCUS_GAIN_TRANSIENT);
//resume music player
am.abandonAudioFocus(null);
I am trying to pause any music player that is installed on the users system.
Thanks