PowerShell for Windows Admins

Apr 14 2014   2:43PM GMT

Status of Office software

Richard Siddaway Richard Siddaway Profile: Richard Siddaway

You can also use the SoftwareLicensingProduct CIM class to test the status of your Office products.

Get-CimInstance -ClassName SoftwareLicensingProduct -Filter “Name LIKE ‘Office%'” |

where PartialProductKey |

select Name, ApplicationId, LicenseStatus

You need to be careful with Office as you might find a lot more options than you expected. On my machine I found this:

Get-CimInstance -ClassName SoftwareLicensingProduct -Filter “Name LIKE ‘Office%'” | select Name -Unique | sort name

Office 15, OfficeO365ProPlusR_Grace edition

Office 15, OfficeO365ProPlusR_Retail edition

Office 15, OfficeO365ProPlusR_Subscription1 edition

Office 15, OfficeO365ProPlusR_Subscription2 edition

Office 15, OfficeO365ProPlusR_Subscription3 edition

Office 15, OfficeO365ProPlusR_Subscription4 edition

Office 15, OfficeO365ProPlusR_Subscription5 edition

Office 15, OfficeO365ProPlusR_SubTrial1 edition

Office 15, OfficeO365ProPlusR_SubTrial2 edition

Office 15, OfficeO365ProPlusR_SubTrial3 edition

Office 15, OfficeO365ProPlusR_SubTrial4 edition

Office 15, OfficeO365ProPlusR_SubTrial5 edition

Office 15, OfficeO365SmallBusPremR_Grace edition

Office 15, OfficeO365SmallBusPremR_Retail edition

Office 15, OfficeO365SmallBusPremR_Subscription1 edition

Office 15, OfficeO365SmallBusPremR_Subscription2 edition

Office 15, OfficeO365SmallBusPremR_Subscription3 edition

Office 15, OfficeO365SmallBusPremR_Subscription4 edition

Office 15, OfficeO365SmallBusPremR_Subscription5 edition

Office 15, OfficeO365SmallBusPremR_SubTrial1 edition

Office 15, OfficeO365SmallBusPremR_SubTrial2 edition

Office 15, OfficeO365SmallBusPremR_SubTrial3 edition

Office 15, OfficeO365SmallBusPremR_SubTrial4 edition

Office 15, OfficeO365SmallBusPremR_SubTrial5 edition

Office 15, OfficeProjectProCO365R_Subscription edition

Office 15, OfficeProjectProCO365R_SubTest edition

Office 15, OfficeProjectProCO365R_SubTrial edition

Office 15, OfficeProjectProDemoR_BypassTrial180 edition

Office 15, OfficeProjectProMSDNR_Retail edition

Office 15, OfficeProjectProO365R_Subscription edition

Office 15, OfficeProjectProO365R_SubTest edition

Office 15, OfficeProjectProO365R_SubTrial edition

Office 15, OfficeProjectProR_Grace edition

Office 15, OfficeProjectProR_OEM_Perp edition

Office 15, OfficeProjectProR_Retail edition

Office 15, OfficeProjectProR_Trial edition

Office 15, OfficeProPlusDemoR_BypassTrial180 edition

Office 15, OfficeProPlusMSDNR_Retail edition

Office 15, OfficeProPlusR_Grace edition

Office 15, OfficeProPlusR_OEM_Perp edition

Office 15, OfficeProPlusR_Retail edition

Office 15, OfficeProPlusR_Trial edition

Office 15, OfficeVisioProCO365R_Subscription edition

Office 15, OfficeVisioProCO365R_SubTest edition

Office 15, OfficeVisioProCO365R_SubTrial edition

Office 15, OfficeVisioProDemoR_BypassTrial180 edition

Office 15, OfficeVisioProMSDNR_Retail edition

Office 15, OfficeVisioProO365R_Subscription edition

Office 15, OfficeVisioProO365R_SubTest edition

Office 15, OfficeVisioProO365R_SubTrial edition

Office 15, OfficeVisioProR_Grace edition

Office 15, OfficeVisioProR_OEM_Perp edition

Office 15, OfficeVisioProR_Retail edition

Office 15, OfficeVisioProR_Trial edition

 

which was a lot more than I expected.

It is possible to use WMI to set the product key – use the SoftwareLicensingService class

 

 Comment on this Post

 
There was an error processing your information. Please try again later.
Thanks. We'll let you know when a new response is added.
Send me notifications when other members comment.

Forgot Password

No problem! Submit your e-mail address below. We'll send you an e-mail containing your password.

Your password has been sent to:

Share this item with your network: