Forum Discussion
johnjohn-Peter
Feb 23, 2025Iron Contributor
Why custom list item versions do not preserve the attachments when restore an old version
I have a custom list which contain custom content type and it allow attachments, now i am storing 100 item versions ..
but i have noted when i restore a previous version of the list item, it will always keep the current attachment and ignore the version attachment, is this a limitation inside SharePoint custom list? and is there any workarounds?
For example on version 1, i have an attachment named 1.docx
and on version 2, i have uploaded another attachment named 2.docx ans remove 1.docx,
but when i restore the item to version 1, i got 2.docx as the attachment instead of 1.docx,
Any advice ?
Thanks
1 Reply
Sort By
- RobSotoIron Contributor
Hi johnjohn-Peter ,
The list item creation and upload of the attachment creates two versions immediately. I created a custom list and added an item. I then checked version history right away and saw two versions.
I then deleted the attachment and replaced it with a new version and checked version history again. There were 4 versions.
This means that restoring an item to a previous version won't also restore the attachment because that action creates a completely separate version. It's also not easy to spot which version is related to the new attachment. I don't see any option around this within a list. If the file attachment is critical to your process, my recommendation would be to shift your approach to use a document library and then add the item's metadata there. That way your version history restore process will happen as you want it to. It might be worth trying out in a test library.
Hope this helps!
-Rob