-
Notifications
You must be signed in to change notification settings - Fork 1k
SharePoint Updates from Word Online not accurate #10133
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
Hello @Kamalasekaran - Thanks for raising your query. |
Hello @Kamalasekaran , |
@Amey-MSFT Below Steps i followed to permit Sites.selected Created Azure AD Enterprise Application with Sites.Selected Permissions After granting Admin Permissions Run the below Powershell to Select the Specific Sharepoint Site Site
Get the output of the AD Application ID and Connect to the SharePoint Site
And the Get the AD application ID and grant the permission |
Hello @Kamalasekaran , |
@Amey-MSFT Sorry for the Miscommunication First I registered the Pnpapp with Allsites.Fullcontrol as A Delegated Permission. Using this new PnPApp I was given Sites.Selected to our AD app with Application Permissions which is mentioned in Last Command. |
Thank you for the clarification! That makes sense now. So, the initial AllSites.FullControl permission was applied during the registration of the PnPApp as a delegated permission, and then Sites.Selected was granted to the AD app with application permissions to limit access to specific sites. Appreciate the explanation. |
Hello @Kamalasekaran , |
Target SharePoint environment
SharePoint Online
What SharePoint development model, framework, SDK or API is this about?
SharePoint CSOM
Developer environment
Windows
What browser(s) / client(s) have you tested
Additional environment details
-Word Online
Describe the bug / error
I’m working on building a SharePoint Webhook integrated with an Azure Function that accesses a SharePoint site using an Azure Entra ID application with the Sites.Selected permission. The goal is to open a SharePoint document in Word Online, edit its content, and then use the SharePoint Webhook to trigger an Azure Function that updates the document’s metadata fields using SystemUpdate(). However, I’ve noticed an issue: if the document remains open in Word Online with AutoSave enabled, the changes made via CSOM seem to get overwritten. I’d like to understand why this is happening and how I can prevent it.
Steps to reproduce
Set Up Azure Entra ID Application:
Register an application in Azure Entra ID.
Create an Azure Function:
Configure SharePoint Webhook:
Create a SharePoint document library in a SharePoint Online site.
Register a Webhook subscription for the document library, pointing to the Azure Function endpoint.
Ensure the Webhook triggers on document changes (e.g., ItemUpdated events).
Upload a Test Document:
Upload a Word document (e.g., TestDoc.docx) to the SharePoint document library.
Edit Document in Word Online:
Open TestDoc.docx in Word Online.
Enable AutoSave (default behavior in Word Online).
Make a content change (e.g., add a sentence) and let AutoSave sync the update.
Trigger Metadata Update via Azure Function:
Simulate or wait for the SharePoint Webhook to trigger the Azure Function (alternatively, manually invoke the function).
Observe Conflict:
Expected behavior
This Happening only with fields updated via SharePoint CSOM with SystemUpdate. If we were using the Update method getting a Version Conflict issue.
The text was updated successfully, but these errors were encountered: