Set-AssignedAccess

Set-AssignedAccess

Configures a user to launch only one app.

構文

Parameter Set: UserNameANDAppName
Set-AssignedAccess -AppName <String> -UserName <String> [-Confirm] [-WhatIf] [ <CommonParameters>]

Parameter Set: UserNameANDAppId
Set-AssignedAccess -AppUserModelId <String> -UserName <String> [-Confirm] [-WhatIf] [ <CommonParameters>]

Parameter Set: UserSidANDAppId
Set-AssignedAccess -AppUserModelId <String> -UserSID <String> [-Confirm] [-WhatIf] [ <CommonParameters>]

Parameter Set: UserSidANDAppName
Set-AssignedAccess -AppName <String> -UserSID <String> [-Confirm] [-WhatIf] [ <CommonParameters>]

詳細説明

The Set-AssignedAccess cmdlet configures the specified user account so that it can use only one Windows Store app. The user cannot exit the app, sign out, or access any system settings.

If a user is signed in or the PC has a PS/2 keyboard, you must restart the computer to apply the changes.

To sign out of assigned access, quickly press the left Windows logo key five times.

パラメーター

-AppName<String>

Specifies the name of the installed Windows Store app to use for assigned access. Wildcard characters are accepted.

エイリアス

なし

必須?

true

位置は?

named

既定値

なし

パイプライン入力を許可する

false

ワイルドカード文字を許可する

true

-AppUserModelId<String>

Specifies the Application User Model ID (AppUserModelID) for the installed Windows Store app to use for assigned access. The AppUserModelID is found in the app's AUMIDs.txt file.

エイリアス

AUMID

必須?

true

位置は?

named

既定値

なし

パイプライン入力を許可する

false

ワイルドカード文字を許可する

false

-UserName<String>

Specifies the local user account name to use for assigned access. This cannot be a domain account or an administrator account.

エイリアス

なし

必須?

true

位置は?

named

既定値

なし

パイプライン入力を許可する

false

ワイルドカード文字を許可する

false

-UserSID<String>

Specifies the security identifier (SID) for the local user account to use for assigned access. This account cannot be a domain account or an administrator account.

エイリアス

なし

必須?

true

位置は?

named

既定値

なし

パイプライン入力を許可する

false

ワイルドカード文字を許可する

false

-Confirm

コマンドレットを実行する前に、ユーザーに確認を求めます。

必須?

false

位置は?

named

既定値

false

パイプライン入力を許可する

false

ワイルドカード文字を許可する

false

-WhatIf

コマンドレットを実行するとどのような結果になるかを表示します。コマンドレットは実行されません。

必須?

false

位置は?

named

既定値

false

パイプライン入力を許可する

false

ワイルドカード文字を許可する

false

<CommonParameters>

このコマンドレットは次の共通パラメーターをサポートします。-Verbose、-Debug、-ErrorAction、-ErrorVariable、-OutBuffer、-OutVariable.詳細については、以下を参照してください。 about_CommonParameters (https://go.microsoft.com/fwlink/p/?LinkID=113216)。

入力

入力型は、コマンドレットにパイプできるオブジェクトの型です。

  • None.

    You cannot pipe input to this cmdlet.

出力

出力型は、コマンドレットによって生成されるオブジェクトの型です。

  • System.Object

  • To get a list of all the Windows Store apps installed for a user account, use the Get-AppxPackage cmdlet as follows:

    Get-AppxPackage -User username

EXAMPLE 1

This example shows how to configure assigned access by using the user SID and the app name.

PS C:\> Set-AssignedAccess -UserSID S-1-5-21-523423449-2432423479-234123443-1004 -AppName CustomApp

EXAMPLE 2

This example shows how to configure assigned access by using the user name and AppUserModelID.

PS C:\> Set-AssignedAccess -UserName UserName -AUMID microsoft.windowsphotos_8wekyb3d8bbwe!app

関連トピック

Get-AssignedAccess

Clear-AssignedAccess