I'm trying to play a sound file in monotouch but it gets cut off after a second or two. Here is the code I'm using to play the sound:
SoundFileName = filename;
var sound = SystemSound.FromFile(filename);
sound.PlaySystemSound();
It's an MP3 file that I'm trying to play. Again, I hear it for a brief second and then it gets cut. I added a thread.sleep() line afterwards and THEN it'll play throughout.
But that's not ideal because the length of the mp3 files that I'm playing could vary. Any help would be greatly appreciated. Thank you.