LicenseInformation.IsTrial | isTrial property

Applies to Windows and Windows Phone

Gets a value that indicates whether the license is a trial license.

Syntax


public bool IsTrial { get; }

Property value

Type: Boolean [JavaScript] | System.Boolean [.NET] | Platform::Boolean [C++]

Returns true if the license is a trial license, and otherwise false.

Remarks

For a trial experience with a trial period, there are some special considerations for interpreting the value of IsTrial. IsTrial returns true even after the trial period ends, because a trial license is logically considered to be a trial license both during and after the trial period. After purchase, when the license becomes full, IsTrial returns false. While IsTrial returns true, there are two ways to tell whether the trial period has expired. If you want to take action the moment the trial period expires then compare the current Coordinated Universal Time (or Zulu time) with ExpirationDate. Otherwise, you can check IsActive, which returns true during the trial period and false some time after the trial period ends.

Note  Be aware that, for an app installed from the Windows Store, it can take some hours after the trial period ends for IsActive to begin returning a value of false. When testing your app with CurrentAppSimulator, IsActive will return false at the exact datetime set in the configuration file.

Requirements

Minimum supported client

Windows 8

Minimum supported server

Windows Server 2012

Minimum supported phone

Windows Phone 8

Namespace

Windows.ApplicationModel.Store
Windows::ApplicationModel::Store [C++]

Metadata

Windows.winmd

See also

LicenseInformation

 

 

Show:
© 2014 Microsoft