Quantcast
Channel: Xamarin.Forms — Xamarin Community Forums
Viewing all articles
Browse latest Browse all 89864

Get .mp3 files from PCL on each platform

$
0
0

Hi

I have a PCL with a subfolder Data/Sounds where i have 360 soundclips

I will play the sound on each platform (Android, IOS and Windows Phone) using DependencyServices.Get<>....
But how can i get the soundclips from my PCL, i've made it earlier in Windows universal apps like this.

`
StorageFile file = await StorageFile.GetFileFromApplicationUriAsync(new Uri(@"ms-appx:///Data/Sounds/" + f));
using (IRandomAccessStream stream = await file.OpenReadAsync())
{
...

`
Thanks

/Jas


Viewing all articles
Browse latest Browse all 89864

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>