ITPub博客

首页 > > > 部署到IIS上后,System.Media.SoundPlayer失效?

部署到IIS上后,System.Media.SoundPlayer失效?

作者:jenliang 时间:2019-09-04 13:35:29 0 删除 编辑

需求就是自动播放bin下的wav音频文件(就是本地播放,不是客户端播放)。

是在一个Web Service里,我调试的时候正常,部署到IIS后就不播放了,也不报任何异常。

System.Media.SoundPlayer sp1 = new System.Media.SoundPlayer("这里是bin下的wav格式音频文件路径");

sp1.Play();

来自 “ ITPUB博客 ” ,链接:https://blog.itpub.net/4565/viewspace-3145000/ ,如需转载,请注明出处,否则将追究法律责任。

请登录后发表评论 登录
全部评论

注册时间:2019-07-15

  • 博文量
    189
  • 访问量
    858