Add addFileAttachmentAsModernAttachmentAsync and addFileAttachmentAsModernAttachmentFromBase64Async

Add addFileAttachmentAsModernAttachmentAsync and addFileAttachmentAsModernAttachmentFromBase64Async
0

Upvotes

Upvote

 Feb 27 2024
0 Comments 
New

Hi!
It is not possible to programmatically add a file as a sharing link in OneDrive or SharePoint.
You can do this from the web or even using VSTO (adding the method 7).

I think there should be one function like addFileAttachmentAsModernAttachmentAsync that would basically take 2 parameters:
The original URL in the web
The sharing method to use
and it should visually add the sharing link with all the options like:

 

Pablo1975_1-1709071504676.png

 

 

The same with addFileAttachmentAsModernAttachmentFromBase64Async. It should take 2 parameters:
The base64 string without any size restriction
The sharing method to use

The functions should do the sharing (with the sharing method like AnyoneCanView or the new "AnyoneCanViewWithPassword") and add the sharing link.

Thanks