PackageVersion PackageVersion PackageVersion PackageVersion PackageVersion Struct


Represents the package version info.

public : struct PackageVersion
struct winrt::Windows::ApplicationModel::PackageVersion
public struct PackageVersion
Public Structure PackageVersion
var packageVersion = {

   build: /* Your value */,

   major: /* Your value */,

   minor: /* Your value */,

   revision: /* Your value */

Windows 10 requirements
Device family
Windows 10 (introduced v10.0.10240.0)
API contract
Windows.Foundation.UniversalApiContract (introduced v1)


Use the Package.Current | current property to get the package for the current app. Use the Package.Id | id property to get the package ID, from wihch you can then get the version.

var package = Windows.ApplicationModel.Package.current;
var packageId =;
var version = packageId.version;

using Windows.ApplicationModel;

Package package = Package.Current;
PackageId packageId = package.Id;
PackageVersion version = packageId.Version;
Dim package As Windows.ApplicationModel.Package = Windows.ApplicationModel.Package.Current
Dim packageId As Windows.ApplicationModel.PackageId = package.Id
Dim version As Windows.ApplicationModel.PackageVersion = packageId.Version
Windows::ApplicationModel::Package^ package = Windows::ApplicationModel::Package::Current;
Windows::ApplicationModel::PackageId^ packageId = package->Id;
Windows::ApplicationModel::PackageVersion version = packageId->Version;


Build Build Build Build Build

The build version number of the package.

Major Major Major Major Major

The major version number of the package.

Minor Minor Minor Minor Minor

The minor version number of the package.

Revision Revision Revision Revision Revision

The revision version number of the package.

See Also