Jump to content

Recommended Posts

Posted

This should be a simple thing to do but for some reason I'm having an issue.

 

insight.

Our accounts are synced with our AD environment. I have exported all students from each OU and created a .csv file to activate their license.

Currently license is active for all users.

 

The issue is when I assigned the license to the users it enabled everything.

I found this page that tells how to disable skype < https://community.office365.com/en-us/w/manage/2603 >

 

So here is what I did.

1. I logged into our AD server and ran powershell as administrator

2. added the msonline module < import-module msonline >

3. I logged in with admin account < $cred = Get-Credential >

4. I connected to office365 < Connect-MsolService -Credential $cred >

5. I checked our accountskuid < xxxxxxxxxxxxxxxx:STANDARDWOFFPACK_IW_STUDENT >

6. I ran the following commands. < $LicenseOption_object_name = New-MsolLicenseOptions -AccountSkuId xxxxxxxxxxxxxxxxxxxx:STANDARDWOFFPACK_IW_STUDENT -DisabledPlans MCOSTANDARD >

< $LicenseOption_object_name.GetType() >

 

< $myO365Sku = New-MsolLicenseOptions -AccountSkuId xxxxxxxxxxxxxx:STANDARDWOFFPACK_IW_STUDENT -DisabledPlans MCOSTANDARD >

< $myO365Sku.GetType() >

 

 

I did not receive any errors but it did not disable skype for the STANDARDWOFFPACK_IW_STUDENT license.

What did I do wrong?

 

Thanks in advanced.

Posted
You can't edit existing licenses with the available powershell commands. You need to remove the licence first, then re-apply it with the desired options. Replacing the licence won't have any negative effects on the mailbox etc.
Posted

Thanks for the reply

 

Would you mind telling me whats needs to be added to this to remove skype for when I re-assign the license?

 

$AccountSkuId = "xxxxxxxxxxxxxxx:STANDARDWOFFPACK_IW_STUDENT"

$UsageLocation = "US"

$Users = Import-Csv c:\temp\users.csv

$Users | ForEach-Object {

Set-MsolUser -UserPrincipalName $_.UserPrincipalName -UsageLocation $UsageLocation

Set-MsolUserLicense -UserPrincipalName $_.UserPrincipalName -AddLicenses $AccountSkuId

}

 

Thanks

Posted

Mr. Ben.

Again thank you for the reply. I'm sorry to inform you that you are wrong though.

 

The following works

 

$Step2 = New-MsolLicenseOptions -AccountSkuId xxxxxxxxxxxxxx:STANDARDWOFFPACK_IW_STUDENT -DisabledPlans EXCHANGE_S_STANDARD, MCOSTANDARD

 

Import-Csv c:\temp\users.csv | ForEach {Set-MsolUserLicense -UserPrincipalName $_.UserPrincipalName -LicenseOptions $Step2}

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now



×
×
  • Create New...