Home ยป Office 365 ยป New-MsolLicenseOptions – Create License Options Object in Office 365

New-MsolLicenseOptions – Create License Options Object in Office 365

The New-MsolLicenseOptions cmdlet in PowerShell creates a license options object in Microsoft Office 365. This command disables specific service plans when you assign a user a license using the Set-MsolUserLicense cmdlet.

The syntax to create a license options object in the Azure Active Directory is given below.

New-MsolLicenseOptions
   -AccountSkuId <String>
   [-DisabledPlans <System.Collections.Generic.List`1[System.String]>]
   [<CommonParameters>]

In this article, we will discuss how to use the New-MsolLicenseOptions cmdlet in PowerShell to disable specific service plans.

How to Create License Options Object

To create a license options object in Office 365, use the New-MsolLicenseOptions cmdlet with the -AccountSkuId and the -DisabledPlans parameters.

The -AccountSkuId parameter specifies the license or account SKU ID. The -DisabledPlans parameter specifies a list of service plans to disable when assigning this license to the user.

New-MsolLicenseOptions -AccountSkuId shellgeeklab:ENTERPRISEPACK -DisabledPlans SWAY,Deskless

This command creates a license options object. This object can be used to disable service plans while assigning a user a license in New-MsolUser or Set-MsolUserLicense cmdlets.

Create a License Options Object
Create a License Options Object

Conclusion

I hope the above article on how to use the New-MsolLicenseOptions cmdlet in PowerShell to create a license options object is helpful to you.

You can find more topics about PowerShell Active Directory commands and PowerShell basics on the ShellGeek home page.

Related Links

New-MsolUser