DocumentIdProvider.GenerateDocumentId Method
Generates a document ID when provided with a list item parameter that corresponds to a document.
Namespace: Microsoft.Office.DocumentManagement
Assembly: Microsoft.Office.DocumentManagement (in Microsoft.Office.DocumentManagement.dll)
Syntax
'Declaration
Public MustOverride Function GenerateDocumentId ( _
listItem As SPListItem _
) As String
'Usage
Dim instance As DocumentIdProvider
Dim listItem As SPListItem
Dim returnValue As String
returnValue = instance.GenerateDocumentId(listItem)
public abstract string GenerateDocumentId(
SPListItem listItem
)
Parameters
listItem
Type: Microsoft.SharePoint.SPListItemAn SPListItem object that specifies the item for which a document ID must be generated.
Return Value
Type: System.String
A string that represents the newly generated Document ID.
Remarks
It is highly recomended that the Document ID generator provides IDs that are both unique and readily type-able by user.