问题
How can you access the list of podcasts on the phone and play them in WP7?
Thanks
回答1:
Currently there is no way you can query podcasts. The Genre won't tell you whether the content you are working with is a podcast or not - MediaLibrary will access the regular songs only and not additional content.
Hopefully the Mango update will carry some extensions for the Media Access API.
回答2:
I was exploring the net to develop a sample for you. After BINGing for a while, suddenly I found this page which has the sample code readily available.
Windows Phone Starter Kit for Podcasts
I hope this helps :)
回答3:
Not sure if there is a specific way to grab just podcasts, but if you know the title of the podcast you could use the Genre property of the Song class and then just iterate through the songs returned by the MediaLibrary
MediaLibrary library = new MediaLibrary();
SongCollection songs = library.Songs;
来源:https://stackoverflow.com/questions/5721776/how-do-you-access-podcasts-in-wp7