Quantcast
Channel: AutoIt v3 - General Help and Support
Viewing all articles
Browse latest Browse all 12506

slmgr.vbs problems

$
0
0
I have been trying to get slmgr.vbs to work from autoit but cant seem to get the darn thing to work

here is my code

$prodkey = "00000-00000-00000-00000-00000"
Func _rekey($key)
RunWait(@ComSpec & " /c " & "cscript %windir%\system32\slmgr.vbs /ipk " & $key, "", @SW_SHOW)
RunWait(@ComSpec & " /c " & "cscript %windir%\system32\slmgr.vbs /ato","",@SW_SHOW)
EndFunc
_rekey($prodkey)


I am sure I have the syntax correct

Quote


Windows Software Licensing Management Tool
Usage: slmgr.vbs [MachineName [User Password]] [<Option>]
           MachineName: Name of remote machine (default is local machine)
           User:        Account with required privilege on remote machine
           Password:    password for the previous account

Global Options:
/ipk <Product Key>
    Install product key (replaces existing key)
/ato [Activation ID]
    Activate Windows
/dli [Activation ID | All]
    Display license information (default: current license)
/dlv [Activation ID | All]
    Display detailed license information (default: current license)
/xpr [Activation ID]
    Expiration date for current license state

Viewing all articles
Browse latest Browse all 12506

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>