WESL_UserSetting.SetCustomShell

This method configures Shell Launcher for a specific user or group, based on the security identifier (SID).

Syntax

[Static] uint32 SetCustomShell (
    [In, Required] string Sid,
    [In, Required] string Shell,
    [In] sint32 CustomReturnCodes[],
    [In] sint32 CustomReturnCodesAction[],
    [In] sint32 DefaultAction
);

Parameters

Sid [in, required] A string containing the security identifier (SID) of the user or group that Shell Launcher is being configured for.

Shell [in, required] The application or executable that Shell Launcher starts as the shell.

CustomReturnCodes [in] An array of custom return codes that can be returned by the shell application.

CustomReturnCodesAction [in] An array of custom return code actions that determine the action that Shell Launcher takes when the shell application exits. The custom actions map to the array of CustomReturnCodes.

The possible actions are defined in the following table:

Value Description

0

Restarts the shell application.

1

Restarts the device.

2

Shuts down the device.

DefaultAction [In] The default action that Shell Launcher takes when the shell application exits.

The possible actions are defined in the following table:

Value Description

0

Restarts the shell application.

1

Restarts the device.

2

Shuts down the device.

Return Value

Returns an HRESULT value that indicates WMI status or a WMI error.

Remarks

Shell Launcher uses the CustomReturnCodes and CustomReturnCodesAction arrays to determine the system behavior when the shell application exits, based on the return value of the shell application.

If the return value does not exist in CustomReturnCodes, or if the corresponding action defined in CustomReturnCodesAction is not a valid value, Shell Launcher uses DefaultAction to determine system behavior. If DefaultAction is not defined, or is not a valid value, Shell Launcher restarts the shell application.

Requirements

Windows Edition Supported
Windows 10 Home No
Windows 10 Pro No
Windows 10 Enterprise Yes
Windows 10 Education Yes

WESL_UserSetting

Shell Launcher