ulvis.paste.net

Paste Search Dynamic
Recent pastes
Find Windows 10 product key us
  1.  
  2. Set WshShell = createobject("WScript.Shell")
  3. MsgBox ConvertToKey(WshShell.RegRead("HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\DigitalProductId"))
  4.  
  5. Function ConvertToKey(Key)
  6. Const KeyOffset = 52
  7. i = 28
  8. Chars = "BCDFGHJKMPQRTVWXY2346789"
  9. Do
  10. Cur = 0
  11. x = 14
  12. Do
  13. Cur = Cur * 256
  14. Cur = Key(x + KeyOffset) + Cur
  15. Key(x + KeyOffset) = (Cur \ 24) And 255
  16. Cur = Cur mod 24
  17. x = x -1
  18. Loop while x >= 0
  19. i = i -1
  20. KeyOutput = Mid(Chars, Cur + 1, 1) & KeyOutput
  21. if (((29 - i) mod 6) = 0) And (i <> -1) then
  22. i = i -1
  23. KeyOutput = "-" & KeyOutput
  24. end if
  25. Loop while i >= 0
  26. ConvertToKey = KeyOutput
  27. end Function
Parsed in 0.013 seconds