UpdateSettings

An optional element of the appinstaller file. UpdateSettings signifies whether or not to check for an update during the app's launch.

Element hierarchy

<AppInstaller>
<UpdateSettings>

Syntax

<UpdateSettings>
    <!-- Child elements -->
    OnLaunch?
    AutomaticBackgroundTask?
    ForceUpdateFromAnyVersion?
</UpdateSettings>

Key

? optional (zero or one)

Attributes and Elements

Attributes

None.

Child Elements

Child Elements Description
OnLaunch OnLaunch signifies that the deployment service will check for an update to the appinstaller file on the app launch.
AutomaticBackgroundTask Checks for updates in the background. A check is made every 8 hours independently of whether the user launched the app. This type of update cannot show UI. Available in Windows 10, version 1803 and later.
ForceUpdateFromAnyVersion A boolean that allows the app's version to be incremented or decremented. Without this element, the app can only move to a higher version. Available starting in Windows 10, version 1809 and later.

Parent Elements

Parent Elements Description
AppInstaller The root element of the appinstaller document.

Remarks

UpdateSettings is an optional element.

Examples

In this example, deployment will check for updates only at launch time and only if 12 or more hours have passed since the last time deployment checked for updates.

<UpdateSettings>
    <OnLaunch HoursBetweenUpdateChecks="12"/>
</UpdateSettings>

In this example, deployment will check for updates in the background, every 8 hours, even if the user doesn't launch the app.

<UpdateSettings>
    <AutomaticBackgroundTask/>
</UpdateSettings>

In this example, deployment will check for updates at launch time and in the background. In addition, the app version can be incremented or decremented.

<UpdateSettings>
    <OnLaunch HoursBetweenUpdateChecks="12"/>
    <AutomaticBackgroundTask/>
    <ForceUpdateFromAnyVersion>true</ForceUpdateFromAnyVersion>
</UpdateSettings>

Requirements

Namespace http://schemas.microsoft.com/appx/appinstaller/2017/2