Set-WssMsoUserLicense

Set-WssMsoUserLicense

Assigns licenses to an account in .

Sintaxis

Parameter Set: Default
Set-WssMsoUserLicense [-WssUserName] <String> [[-License] <MSOLicense[]> ] [ <CommonParameters>]

Descripción detallada

The Set-WssMsoUserLicense cmdlet assigns licenses to an online service account in .

Parámetros

-License<MSOLicense[]>

Specifies an array of licenses as MSOLicense objects. The cmdlet assigns the licenses that you specify to a user account. To obtain MSOLicense objects, use the Get-WssMsoSubscription cmdlet to get subscription information. Subscription information contains the MSOLicenseSuite array that refers to MSOLicense objects.

Alias

ninguno

¿Requerido?

false

¿Posición?

2

Valor predeterminado

ninguno

¿Aceptar canalización?

True (ByPropertyName)

¿Aceptar caracteres comodín?

false

-WssUserName<String>

Specifies the name of the user account to which you want the licenses assigned.

Alias

ninguno

¿Requerido?

true

¿Posición?

1

Valor predeterminado

ninguno

¿Aceptar canalización?

True (ByValue, ByPropertyName)

¿Aceptar caracteres comodín?

false

<CommonParameters>

Este cmdlet admite los siguientes parámetros comunes: -Verbose, -Debug, -ErrorAction, -ErrorVariable, -OutBuffer y -OutVariable. Para obtener más información, consulte about_CommonParameters (https://go.microsoft.com/fwlink/p/?LinkID=113216).

Entradas

El tipo de entrada es el tipo de los objetos que se pueden canalizar al cmdlet.

  • System.String

    WssUserName
    Type: System.String
    Description: local network account name of user

Salidas

El tipo de resultado es el tipo de objetos que emite el cmdlet.

Ejemplos

Example 1: Store a license for a user

The first command uses the Get-WssMsoSubscription cmdlet to get subscription information, and then stores it in the $Subscribe variable.

The second command assigns a license, contained in the object stored in the $Subscribe variable, to the account named EvanNarvaez. The command uses standard array notation to access the first member of the MSOLicenseSuite array, and refer to the associated MSOLicense object.

PS C:\> $Subscribe = Get-WssMsoSubscription
PS C:\> Set-WssMSOUserLicense -WssUserName "EvanNarvaez" -License $Subscribe.MSOLicenseSuite[0].MSOLicense

Temas relacionados

Get-WssMsoSubscription