简体   繁体   中英

Background Audio Windows Phone 8.1 XAML app crashes

I have built an cross-platform app that involves playing audio (podcast mp3 files) in the background.

I have followed the examples as best as I can for performing background audio on Windows Phone 8.1 XAML apps. It will launch and try to start sometimes giving a second or two of audio, and then I get this in the output:

The program '[3284] Windows.Media.BackgroundPlayback.exe' has exited with code 1 (0x1).

I don't even know where to look from here. It doesn't seem to raise an actual exception in the application itself. Any idea what is wrong or how to further troubleshoot this?

Please check these items:

  1. You passed full class name into the Package.appxmanifest (see here example)
  2. You referenced task project from main project ( download Microsoft example and try to copy project references idea)
  3. Both projects have the same Windows Phone version (eg 8.1, 10, etc.)
  4. The Task project has output type Windows Runtime Component (not Class Library )
  5. And of course: try to remove all files except Backround Task and repeat items above again.

就我而言,问题是通过卸载已安装的应用程序并再次部署来解决的。

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM