Monday, June 27, 2022
HomeiOS Developmentc# - Videofile sharing problem with Xamarin.Necessities

c# – Videofile sharing problem with Xamarin.Necessities

I am utilizing the subsequent code:

   await Share.RequestAsync(new ShareFileRequest
      Title = filename,
      File = new ShareFile(filename),
      PresentationSourceBounds = new System.Drawing.Rectangle(0, 0, 1, 1)
catch (Exception)

and now I am attempting to share totally different file varieties. ASCII and binary recordsdata may very well be shared with none issues, however after I’m attempting to share videofile, e.g. /var/cellular/Containers/Knowledge/Software/xxxxx/Library/Caches/app_2022_06_14_17_58_13.mp4, Dropbox reveals a message Could not load file. Sorry, an error occured, others locations akin to Save to recordsdata does not present error however file will not be written.

I attempted to specify file media kind with File = new ShareFile(filename, "video/mp4"), or to make use of library asset file like assets-library://asset/asset.mp4?id=xxxxx&ext=mp4, however this does not assist.

I am utilizing Xamarin.Necessities 1.7.3, iOS model is 15.5

What may very well be a cause? Thanks upfront.



Please enter your comment!
Please enter your name here

Most Popular

Recent Comments