Mono Class Library: System.Version Overview | MembersSystem.Version.Major Property |
Gets the value of the major component of the current instance. [Edit]
|
A int specifying the major component. [Edit]
This property is read-only.
If the version number is 6.1, the major version is 6.
[Edit]
C# Example using System; class VersionMajorExample { public static void Main() { Version vers = new Version("6.1.2.4"); Console.Write("The major component "); Console.WriteLine("of version vers = {0}.", vers.Major); } }The output is
The major component of version vers = 6.
Namespace: System
Assembly: mscorlib (in mscorlib.dll)
Assembly Versions: 1.0.5000.0, 2.0.0.0