Weird one this.
In a ViewController I call the following code in ViewDidLoad():
AudioSession.Initialize();
AudioSession.Category = AudioSessionCategory.MediaPlayback;
AudioSession.SetActive(true);
Then in response to some button presses I do:
NSError err;
var ap = AVAudioPlayer.FromUrl(new NSUrl("mysound.caf"), out err);
ap.FinishedPlaying += delegate { ap.Dispose(); };
ap.Play();
And this works great, pretty responsive etc.
Except sometimes, seemingly randomly, I get the following unhandled
exception in release mode on the device (iPhone 3GS):
System.MissingMethodException: No constructor found for
MonoTouch.AVFoundation.InternalAVAudioPlayerDelegate::.ctor(System.IntPtr)
Any ideas? Google comes up blank for that specific missing constructor.
Thanks
Tom
--
Tom Fanning
_______________________________________________
MonoTouch mailing list
[email protected]
http://lists.ximian.com/mailman/listinfo/monotouch