0
votes

I have SharePoint Online enabled for my Dynamics CRM Online. I have a documents subgrid showing on my account form. Everytime a document is uploaded to Sharepoint from within CRM, an email should be fired to the owner of the record.

I tried using this with Flow but it is difficult as the SharePoint Folder structure is as follows: Account > AccountI_GUID

AccountII_GUID and so on

I could have alerts in SharePoint enabled. However, I would have to do this each time a new account is created in CRM. There is 13000 accounts in CRM already. So, I would have to go into each of the folders and enable alerts.

Would you have any other solutions?

I was thinking of maybe getting a count of all the documents in SP and showing the count in CRM. If the count has changed then trigger a workflow. But I am not sure how to go about that. Please help.

1

1 Answers

0
votes

I would probably go about this by creating a Powershell script to iterate through all of the account document libraries to set up an alert on each one. You could then run this at the end of each day to pick up any new accounts.

After a quick google I came up with this which may be of use Create Alerts using CSOM

I know there are also ways in Dyanamics to remove the GUID from the library but I'm no Dynamics expert so not sure what functionality this may effect.