Are you attending Connect IT Global? Make sure to book your hotel rooms before the special conference rates end TODAY.

Windows License Status

p.vieira Member CHOCOLATE MILK

Looking to see if it would be possible to create a procedure that would allow us to find out of a desktop/server is properly licensed or is deactivated. Has anyone got this to successfully work?

1 votes

Awaiting Votes · Last Updated


  • Miguel Cortinas
    Miguel Cortinas Member CHOCOLATE MILK

    This is what I use for the servers:

    I think works perfectly.

    The magic it is to execute on powershell this script:

    ((cscript c:\windows\system32\slmgr.vbs /dlv | find 'Timebased activation expiration:')-split') (',-1,'simplematch'-Split'day',-1,'SimpleMatch' | select -Skip 1 -First 1)

    It will give you, in case the license it is temporary, the number of days left for the expiration.

  • p.vieira
    p.vieira Member CHOCOLATE MILK

    Thank you Miguel! Will definitely try this out.