Francis Lennert (France) Posted November 19, 2005 Share Posted November 19, 2005 Hello All, I try to find where is the Word, Excel or Office SN in the Regs I know that is not directly an AutoIt question but if someone has the answer, that would help me. My customers allways lose their SN and or CD and I want to create a little AutoIt script which retrieves and shows them. Many thanks, Francis PS: Don't ever try to do this kind of search in Google "Serial number Word Excel" because you will have 1000000 links to Cracks Sites... Link to comment Share on other sites More sharing options...
BigDod Posted November 19, 2005 Share Posted November 19, 2005 Hello All,I try to find where is the Word, Excel or Office SN in the Regs I know that is not directly an AutoIt question but if someone has the answer, that would help me.My customers allways lose their SN and or CD and I want to create a little AutoIt script whichretrieves and shows them.Many thanks,FrancisPS: Don't ever try to do this kind of search in Google "Serial number Word Excel" because you will have 1000000 links to Cracks Sites... There are utilities that can be bought that can do this for you. Time you enjoyed wasting is not wasted time ......T.S. Elliot Suspense is worse than disappointment................Robert Burns God help the man who won't help himself, because no-one else will...........My Grandmother Link to comment Share on other sites More sharing options...
Francis Lennert (France) Posted November 19, 2005 Author Share Posted November 19, 2005 There are utilities that can be bought that can do this for you.Thanks for the answer.I thought that is more easy and that a script could do that.Have a nice day,Francis Link to comment Share on other sites More sharing options...
BigDod Posted November 19, 2005 Share Posted November 19, 2005 Thanks for the answer.I thought that is more easy and that a script could do that.Have a nice day,FrancisSearching through the registry can only find the product id and I do not know of a way to convert that to the product key without using some other utility. Time you enjoyed wasting is not wasted time ......T.S. Elliot Suspense is worse than disappointment................Robert Burns God help the man who won't help himself, because no-one else will...........My Grandmother Link to comment Share on other sites More sharing options...
BigDod Posted November 19, 2005 Share Posted November 19, 2005 I found this on the forums. expandcollapse popupDim $Bin $Bin = RegRead("HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion","DigitalProductID") InputBox("Product Key", "Your " & @OSVERSION & " product key is:", DecodeProductKey($bin), "", -1, 100, -1, -1) Func DecodeProductKey($BinaryDPID) Local $bKey[15] Local $sKey[29] Local $Digits[24] Local $Value = 0 Local $hi = 0 local $n = 0 Local $i = 0 Local $dlen = 29 Local $slen = 15 Local $Result $Digits = StringSplit("BCDFGHJKMPQRTVWXY2346789","") $binaryDPID = stringmid($binaryDPID,105,30) For $i = 1 to 29 step 2 $bKey[int($i / 2)] = dec(stringmid($binaryDPID,$i,2)) next For $i = $dlen -1 To 0 Step -1 If Mod(($i + 1), 6) = 0 Then $sKey[$i] = "-" Else $hi = 0 For $n = $slen -1 To 0 Step -1 $Value = Bitor(bitshift($hi ,- 8) , $bKey[$n]) $bKey[$n] = int($Value / 24) $hi = mod($Value , 24) Next $sKey[$i] = $Digits[$hi +1] EndIf Next For $i = 0 To 28 $Result = $Result & $sKey[$i] Next Return $Result EndFunc Perhaps you could modify it to do what you want or persuade someone to. Time you enjoyed wasting is not wasted time ......T.S. Elliot Suspense is worse than disappointment................Robert Burns God help the man who won't help himself, because no-one else will...........My Grandmother Link to comment Share on other sites More sharing options...
herewasplato Posted November 19, 2005 Share Posted November 19, 2005 (edited) ...I found this on the forums...I think that credit for this script goes to bcording: http://www.autoitscript.com/forum/index.php?showtopic=1506 ...I [bcording]have tested the DecodeProductKey function with Windows 2000, Windows XP, Office XP Pro/Std, Project 2002, Virtual PC 2004 and Visual Studio 2003 Professional. When the Registry Enumeration function is complete these will all be added...till then. I've been using this for some time now. [Thanks bcording!] I changed this:$Bin = RegRead("HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion","DigitalProductID") InputBox("Product Key", "Your " & @OSVERSION & " product key is:", DecodeProductKey($bin), "", -1, 100, -1, -1) To this for Office2003:$Bin = RegRead("HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Office\11.0\Registration\{90110409-6000-11D3-8CFE-0150048383C9}","DigitalProductID") InputBox("Product Key", "Your Office2003 product key is:", DecodeProductKey($bin), "", -1, 100, -1, -1) To this for OfficeXP:$Bin = RegRead("HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Office\10.0\Registration\{90280409-6000-11D3-8CFE-0050048383C9}","DigitalProductID") InputBox("Product Key", "Your OfficeXP product key is:", DecodeProductKey($bin), "", -1, 100, -1, -1) To date, that is all that I've needed... and I've only used this on W2k and Xp OS. Caveat: I do not know if I did the changes correctly, but it has worked on every system that I have used it on. Edited November 19, 2005 by herewasplato [size="1"][font="Arial"].[u].[/u][/font][/size] Link to comment Share on other sites More sharing options...
Francis Lennert (France) Posted November 19, 2005 Author Share Posted November 19, 2005 Many thanks to all. This seems to be perfect.. Francis Link to comment Share on other sites More sharing options...
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now