windows-itpro-docs/windows/configuration/shell-launcher/wesl-usersettingsetdefaultshell.md
Paolo Matarazzo 21a9b5ee91 timestamps
2025-03-07 12:03:40 -05:00

1.2 KiB

title, description, ms.date, ms.topic
title description ms.date ms.topic
WESL_UserSetting.SetDefaultShell WESL_UserSetting.SetDefaultShell 3/7/2025 reference

WESL_UserSetting.SetDefaultShell

This method sets the default Shell Launcher configuration.

[!INCLUDE shell-launcher]

Syntax

[Static] uint32 SetDefaultShell (
    [In, Required] string Shell,
    [In, Required] sint32 DefaultAction
);

Parameters

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

DefaultAction
[in, required] The default action that Shell Launcher takes when the Shell application exits.

The possible actions are defined in the following table:

Value Description
0 Restart the shell.
1 Restart the device.
2 Shut down the device.
3 Do nothing.

Return Value

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

Remarks

Shell Launcher uses the default configuration when the security identifier (SID) of the user who is currently signed in does not match any custom defined Shell Launcher configurations.