Due to third party Software installed in our SharePoint environment we have a number of documents with the same DocumentID. I am working on a PowerShell script that will check each item and assign a new DocumentID to the item if it is not unique.

However I have run into an issue when trying to find properties that make up the actual DocumentID within SharePoint. I realise that the first part of the ID is the Prefix that is set at the Site Collection Level and the last part is the Document Item ID of the document from the Library in which it is stored. I have managed to access these properties fine in PowerShell. My issue comes when I have been trying to find out how to access the middle part of the Document ID, I have looked into this and have seen threads where this is described as the ID of the list in which the Document is stored? I have tried looking at list properties but I have not come across the ID I am looking for, I have only been able to get the GUID of the list.

Any help that suggests I am along the right track and even anyone who knows how to access this value in SharePoint would be greatly appreciated.

1 Answer 1


In theory each list in a site collection will have a unique ID much like the List Item ID. You can see it via:


You will need to clear all the docid settings for each item, get an instance of the DOCID provider and call GenerateDocumentID:

$provider = [Microsoft.Office.DocumentManagement.DocumentId]::GetProvider($site)

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

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