示例#1
0
 private void RulesEnginePlayWindowsAudio(object sender, PlayWindowsAudioEventArgs args)
 {
     // note: not doing an invoke because so far this code doesn't require the UI thread
     _soundService.Play(args.Location);
 }
示例#2
0
 private void RulesEnginePlayWindowsAudio(object sender, PlayWindowsAudioEventArgs args)
 {
     // note: not doing an invoke because so far this code doesn't require the UI thread
     System.Reflection.Assembly a = System.Reflection.Assembly.GetExecutingAssembly();
     Stream s = a.GetManifestResourceStream(args.Location);
     SoundPlayer player = new SoundPlayer(s);
     player.Play();
 }