Export (0) Print
Expand All
This topic has not yet been rated - Rate this topic

SPFileVersionCollection class

Represents a collection of SPFileVersion objects.

Namespace:  Microsoft.SharePoint
Assembly:  Microsoft.SharePoint (in Microsoft.SharePoint.dll)
[ClientCallableTypeAttribute(Name = "FileVersionCollection", ServerTypeId = "3826e282-67a6-4861-88fb-474e8aac897b", 
	CollectionIndexerMethodClientName = "GetById", CollectionChildItemType = typeof(SPFileVersion), 
	SampleUrl = "{apiroot}/web/folders/getbyurl({folderrelativeurl})/files/getbyurl({filerelativeurl})/versions")]
[SubsetCallableTypeAttribute]
public class SPFileVersionCollection : SPBaseCollection

Use the Versions property of the SPFile class to return the collection of versions for a file.

Use an indexer to return a single version from the collection. For example, assuming the collection is assigned to a variable named myVersions, use myVersions[index] in C#, or myVersions(index) in Microsoft Visual Basic, where index is the index number of the version in the collection.

Any public static (Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.
Did you find this helpful?
(1500 characters remaining)
Thank you for your feedback

Community Additions

ADD
Show:
© 2014 Microsoft. All rights reserved.