0

I am trying to share a folder with an external user, I get the URL of the folder on console.log. But how can I send it directly to the user?

This code shares a file with an external user, but it can't send an email in order to inform him. Any suggestion?

sp
 .web
 .getFolderByServerRelativeUrl("/sites/contoso/SharedFiles/test")
 .shareWith("mymail@gmail.com", SharingRole.View, true, true, { body: 'test' })
 .then((result: SharingResult) => {
    console.log(result);
 })
  • thank you for editing Mohamed. – Aris Vang Dec 23 '19 at 10:06
0

This code works fine, in addition you can add in email property a subject. My bad it sent into the junk box.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.