Поделиться через


WEMSAL_Setting (Industry 8.1)

7/8/2014

Review the syntax, members, and examples of the WEMSAL_Setting WMI provider class for Windows Embedded 8.1 Industry (Industry 8.1).

This Windows Management Instrumentation (WMI) provider class configures the general settings for Windows 8 Application Launcher.

Syntax

class WEMSAL_Setting {
    [read, write, key, Required] string InstanceName;
    [read, write] boolean Enabled;
    [read, write] boolean KioskMode;
    [read, write] sint32 FatalErrorAction;
};

Members

The following tables list any methods and properties that belong to this class.

Methods

This class contains no methods.

Properties

Property

Data type

Qualifiers

Description

InstanceName

string

[read, write, key, required]

A unique ID. This is always set to WEMSAL_Setting.

Enabled

Boolean

[read, write]

Indicates if Windows 8 Application Launcher is enabled. If Enabled is false when a user signs in, then Windows 8 Application Launcher does not run.

KioskMode

Boolean

[read, write]

Indicates if the Start screen is displayed while Windows 8 Application Launcher is running.

If set to true, the Start screen is not displayed, and you cannot set the FatalErrorAction, CustomReturnCodesAction, or DefaultReturnCodeAction properties to exit Windows 8 Application Launcher.

FatalErrorAction

sint32

[read, write]

An integer value that specifies the action that Windows 8 Application Launcher takes when it cannot launch the configured Windows Store app.

The following values are the valid actions:

ValueDescription
1Restart the device.
2Shut down the device.
3Close Windows 8 Application Launcher. This value is not valid if KioskMode is set to true.
4Sign out the current user.

Remarks

You must use an administrator account to change any properties in this class.

By default, Enabled is set to false. You must set Enabled to true in order to run Windows 8 Application Launcher automatically when a user signs in.

If KioskMode is set to true, a blank screen is displayed any time that the Start screen would have been displayed. The color of the blank screen matches the color that is selected for the Start screen in PC Settings.

Important

If KioskMode is set to true, the Start screen is not displayed, even if Windows 8 Application Launcher is disabled. Make sure that KioskMode is set to false whenever Enabled is set to false.

If Windows 8 Application Launcher cannot launch the configured Windows Store app, the default experience by a user is that the user account is signed out. This can happen when the Windows Store app is not installed for the user, or if the Windows Store app is otherwise disabled.

In this scenario, you can either set the Enabled property to false or set the FatalErrorAction property to 3 in order to enable the user to install or reinstall the Windows Store app.

Example

The following Windows PowerShell script demonstrates how to use this class to modify the general settings for Windows 8 Application Launcher. This example enables Windows 8 Application Launcher, configures Windows 8 Application Launcher to hide the Start screen, and configures Windows 8 Application Launcher to sign out of the user session if it cannot launch the configured Windows Store app.

#---Define variables---

$COMPUTER = "localhost"
$NAMESPACE = "root\standardcimv2\embedded"

# Get the current settings values.

$LauncherSettings = get-wmiobject –namespace $NAMESPACE –computer $COMPUTER –class WEMSAL_Setting

# Enable Windows 8 Application Launcher.
$LauncherSettings.Enabled = $true

# Configure Windows 8 Application Launcher to sign out if it cannot launch the Windows Store app.
$LauncherSettings.FatalErrorAction = 4

# Configure Windows 8 Application Launcher to hide the Start screen.
$LauncherSettings.KioskMode = $true

# Save the updated settings.
$LauncherSettings.put()

See Also

Concepts

Windows 8 Application Launcher WMI provider reference
Windows 8 Application Launcher