[MonoTouch] How to play .3gp audio file using MonoTouch?

Rolf Bjarne Kvinge rolf at xamarin.com
Tue Oct 4 09:10:09 EDT 2011


Hi,

Can you post the stack trace? And does it play if you remove that line?

Rolf

On Mon, Oct 3, 2011 at 8:41 AM, bharath <bharath.cd at gmail.com> wrote:
> How to play .3gp audio file using MonoTouch? I have used like this,
>
> var mediaFile = NSUrl.FromFilename("song.3gp");
> var audioPlayer = AVAudioPlayer.FromUrl(mediaFile);
> audioPlayer.FinishedPlaying += delegate { audioPlayer.Dispose(); };
> audioPlayer.Play();
>
> But I got NullReferenceException on this line,
>
> audioPlayer.FinishedPlaying += delegate { audioPlayer.Dispose(); };
>
> How to play this song?
>
> -----
> Bharath
> --
> View this message in context: http://monotouch.2284126.n4.nabble.com/How-to-play-3gp-audio-file-using-MonoTouch-tp3866710p3866710.html
> Sent from the MonoTouch mailing list archive at Nabble.com.
> _______________________________________________
> MonoTouch mailing list
> MonoTouch at lists.ximian.com
> http://lists.ximian.com/mailman/listinfo/monotouch
>


More information about the MonoTouch mailing list