In the past, I've been able to update the Modified and Modified By fields of files in a SharePoint library (note: library, not list) by making an HTTP request to ValidateUpdateListItem. It's described here - #FlowNinja hack 78 - modifying Modified By and Modified time with Microsoft Flow — John Liu .NET. Unfortunately, this now seems to have stopped working.
This is the body of the request.
{"formValues":[
{
"FieldName":"Editor",
"FieldValue":"[{'Key':'i:0#.f|membership|***email***'}]"
},
{
"FieldName":"Title",
"FieldValue":"000000000test.docx"
},
{
"FieldName":"FileLeafRef",
"FieldValue":"000000000test.docx"
},
{
"FieldName":"Modified",
"FieldValue":"2024-03-18 16:20:00Z"
}
],
"bNewDocumentUpdate":true,
"datesInUTC":true
}
The file is renamed correctly but the actual modified time is the time the flow runs, and the user who modified it is set to myself.
Response:
{
"d": {
"ValidateUpdateListItem": {
"__metadata": {
"type": "Collection(SP.ListItemFormUpdateValue)"
},
"results": [
{
"ErrorCode": 0,
"ErrorMessage": null,
"FieldName": "Editor",
"FieldValue": "[{'Key':'i:0#.f|membership|***email address***'}]",
"HasException": false,
"ItemId": 326
},
{
"ErrorCode": 0,
"ErrorMessage": null,
"FieldName": "Title",
"FieldValue": "000000000test.docx",
"HasException": false,
"ItemId": 326
},
{
"ErrorCode": 0,
"ErrorMessage": null,
"FieldName": "FileLeafRef",
"FieldValue": "000000000test.docx",
"HasException": false,
"ItemId": 326
},
{
"ErrorCode": 0,
"ErrorMessage": null,
"FieldName": "Modified",
"FieldValue": "2024-03-18 16:20:00Z",
"HasException": false,
"ItemId": 326
}
]
}
}
}
What I've tried:
- Setting the Modified By field at the same time
- Adjusting the Read Only attribute on Modified to false
- Adjusting the Read Only attribute on Last Modified to false
- Adjusting the Read Only attribute on Last Modified Date to false
- Setting a different DateTime column with the same value, to check my formatting isn't at fault
I have had no success with the above. Can anyone suggest what might be the issue?

Report
All responses (
Answers (