XamarinMediaManager icon indicating copy to clipboard operation
XamarinMediaManager copied to clipboard

Duration returning as zero on Audio

Open sb111111111 opened this issue 3 years ago • 2 comments

🐛 Bug Report

When trying to retrieve the total duration of audio file it is returning 00:00:00

Expected behaviour

Duration of the audio file to be returned

Reproduction steps

        var mediaItem = await CrossMediaManager.Current.Play(audioFile);
        var duration = mediaItem.Duration;
        await DisplayAlert("info", duration.ToString(), "OK");

Configuration

Version: 1.1.1

Platform: Xamarin.Forms

sb111111111 avatar Jul 28 '22 10:07 sb111111111

did you find how to solve this error?

RamyOscar avatar Oct 26 '22 10:10 RamyOscar

I'm seeing this same issue on iOS only - Android works as expected returning the duration value.

c0demak3r avatar May 29 '23 13:05 c0demak3r