question

WeiWen-3421 avatar image
0 Votes"
WeiWen-3421 asked WenyanZhang-MSFT commented

Playing audio using Plugin.AudioRecorder.AudioPlayer.Play() caused crash on xamarin.forms iOS

The player works fine on Android. On iOS, I can record, and play audio usingAudioPlayer.Play() since the file is stored locally on the device. But after the file is uploaded to Azure website and I used the link to play, the app crashed with the message:

Could not initialize an instance of the type 'AVFoundation.AVAudioPlayer': the native 'initWithContentsOfURL:error:' method returned nil.

Here is a link of the audio file:
https://knownow.blob.core.windows.net/otherfiles/de3a8b34-eb2c-4a84-a63a-df8ed253594f_ARS_recording.wav?sv=2020-04-08&st=2021-09-27T13%3A10%3A26Z&se=2021-09-27T14%3A10%3A26Z&sr=c&sp=r&sig=JnLBMZwHJO7nCXgZ3GCAvG4nfznVcah7wgb2%2B8VP3Vs%3D

I wonder if there are special characters in the link that iOS does not like?


dotnet-xamarinforms
· 1
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

0 Answers