protected override void OnBeginStreaming(AudioTrack track, AudioStreamer streamer) { System.Diagnostics.Debug.WriteLine("OnBeginStreaming"); MidiStreamSource mss = new MidiStreamSource(); // Event handler for when a track is complete or the user switches tracks mss.StreamComplete += new EventHandler(mss_StreamComplete); // Set the source streamer.SetSource(mss); }