SPFile.MajorVersion property

Gets the major version of the file.

Namespace:  Microsoft.SharePoint
Assembly:  Microsoft.SharePoint (in Microsoft.SharePoint.dll)

Syntax

'Declaration
Public ReadOnly Property MajorVersion As Integer
    Get
'Usage
Dim instance As SPFile
Dim value As Integer

value = instance.MajorVersion
public int MajorVersion { get; }

Property value

Type: System.Int32
A 32-bit integer that indicates the major version.

Remarks

A version number consists of a major and a minor version. For example, the version number 3.2 specifies “3” as the major version and “2” as the minor version.

See also

Reference

SPFile class

SPFile members

Microsoft.SharePoint namespace