Custom Query

Filters
 
Or
 
  
 
Columns

Show under each result:


Results (262 - 264 of 3893)

Ticket Resolution Summary Owner Reporter
#805 No Bug Don't really know what command is causing the problem Emiel Wieldraaijer
Description

I use a script from Danny35d to display office and windows serials. After updating to 3.3.0.0 the returned information is not correct anymore.

#include <Array.au3>

$HKLM = "HKEY_LOCAL_MACHINE"
If @OSArch = "X64" Then 
	$HKLM &= "64"
EndIf

$OfficeKey = _GetOfficeKey()

_ArrayDisplay($OfficeKey, 'Office Key')

$HKLM = "HKEY_LOCAL_MACHINE"
If @OSArch = "X64" Then 
	$HKLM &= "64"
EndIf

;===============================================================================
;
; Function Name:    _GetWindowsKey()
; Description:      gets the Windows DigitalProductID from the registry
; Parameter(s):     none
; Requirement(s):   none
; Return Value(s):  Returns the binary Windows DigitalProductID as stored in the registry
; Author(s):        Danny35d
;
;===============================================================================
; TBD: Error checking and SetError
Func _GetWindowsKey($sRemoteComputer = '')
    Dim $aKeys[2][5]
    
    If $sRemoteComputer <> '' Then $sRemoteComputer = '\\' & StringReplace($sRemoteComputer, '\', '') & '\'
    Local Const $sRegKey = $sRemoteComputer & $HKLM & '\SOFTWARE\Microsoft\Windows NT\CurrentVersion'
    
    $aKeys[0][0] = 1
    $aKeys[1][0] = RegRead($sRegKey, 'ProductName')
    $aKeys[1][1] = RegRead($sRegKey, 'ProductID')
    $aKeys[1][2] = _DecodeProductKey(RegRead($sRegKey, 'DigitalProductID'))
    $aKeys[1][3] = RegRead($sRegKey, 'RegisteredOwner')
    $aKeys[1][4] = RegRead($sRegKey, 'RegisteredOrganization')
    Return($aKeys)
EndFunc   ;==>_GetWindowsKey

;===============================================================================
;
; Function Name:    _GetOfficeKey()
; Description:      gets the Office DigitalProductID from the registry
; Parameter(s):     none
; Requirement(s):   none
; Return Value(s):  Returns the binary 2003 Office DigitalProductID as stored in the registry
; Author(s):        Danny35d
;
;===============================================================================
; TBD: Error checking and SetError
Func _GetOfficeKey($sRemoteComputer = '')
    Dim $aKeys[1][3]
    If $sRemoteComputer <> '' Then $sRemoteComputer = '\\' & StringReplace($sRemoteComputer, '\', '') & '\'
    Local $sRegKey1 = $sRemoteComputer & $HKLM & '\SOFTWARE\Microsoft\Office'
    Local $sRegKey2 = $sRemoteComputer & $HKLM & '\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall'
    Local $iCount1 = 1, $iCount2 = 1
    
    While 1
        $sKey1 = RegEnumKey($sRegKey1, $iCount1)
        If @error <> 0 Then ExitLoop
        While 1
            $ProductID = ''
            $ProductName = ''
            $DigitalProductID = ''
            $sKey2 = RegEnumKey($sRegKey1 & '\' & $sKey1 & '\Registration', $iCount2)
            If @error <> 0 Then ExitLoop
            $ProductID = RegRead($sRegKey1 & '\' & $sKey1 & '\Registration\' & $sKey2, 'ProductID')
            $ProductName = RegRead($sRegKey1 & '\' & $sKey1 & '\Registration\' & $sKey2, 'ProductName')
            $DigitalProductID = RegRead($sRegKey1 & '\' & $sKey1 & '\Registration\' & $sKey2, 'DigitalProductID')
			$InstallPath = StringTrimRight((RegRead ($sRegKey1 & '\' & $sKey1 & '\Common\InstallRoot', 'Path')),1)
			$ProductVersion = RegRead($sRegKey1 & '\' & $sKey1 & '\Common\Productversion', 'Lastproduct')
			$OfficeLanguage = StringRight(Hex(RegRead($sRegKey1 & '\' & $sKey1 & '\Common\LanguageResources', 'SKULanguage')),4)
			
            If $ProductName = '' Then $ProductName = RegRead($sRegKey2 & '\' & $sKey2, 'DisplayName')
            $DigitalProductID = _DecodeProductKey($DigitalProductID)
            If $DigitalProductID <> 'BBBBB-BBBBB-BBBBB-BBBBB-BBBBB' Then 
                ReDim $aKeys[UBound($aKeys) + 1][6]
                $aKeys[0][0] = UBound($aKeys) - 1
                $aKeys[UBound($aKeys) - 1][0] = $ProductName
                $aKeys[UBound($aKeys) - 1][1] = $ProductID
                $aKeys[UBound($aKeys) - 1][2] = $DigitalProductID       
				$aKeys[UBound($aKeys) - 1][3] = $InstallPath
				$aKeys[UBound($aKeys) - 1][4] =	$ProductVersion
				$aKeys[UBound($aKeys) - 1][5] = $OfficeLanguage
            EndIf
			
            $iCount2 += 1
        WEnd        
        $iCount1 += 1      
    WEnd
    Return($aKeys)
EndFunc   ;==>_GetOfficeKey

;===============================================================================
;
; Function Name:    _DecodeProductKey()
; Description:      decodes the PID to get the product key
; Parameter(s):     $BinaryDPID - the PID as stored in registry
; Requirement(s):   none
; Return Value(s):  Returns the decoded Windows/Office/Visual studio/etc. product key
; Author(s):        found this in the Forum, who made it?!
;
;===============================================================================
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   ;==>_DecodeProductKey
#869 Completed @OSLang will not detect MUI enviroments Emiel Wieldraaijer
Description

Hi All,

I have Vista Ultimate English and have installed several MUI for other languages.

@OSLang will allways return English regardless if i choose Dutch/German/Bulgarian/Russian/Swedish....... (and all the rest)

In HKCU\Control Panel\Appearance there is a Binary value SchemeLangID which represents the MUI selected in Ultimate (don't know if it's the same in other MUI OS)

for Example

The Binary value is

0x0904 = English 0x1304 = Dutch 0x0204 = Bulgarian

The Hex value of the binary value

0904 = English 1304 = Dutch 0204 = Bulgarian

OSLang value for English = 0409 OSLang value for Dutch = 0413 OSLang value for Bulgarian = 0402

So basicly the same

only switched in pairs of two

Vista Business (does not have MUI builtin) also uses the SchemeLangID registry value.

Using the @OSLang is handy for Multi Langual versions of programs. So maybe @OSLang needs some updating.

Thanks

Emiel

#1018 Rejected SplashImageOn example not correct for Vista Emiel Wieldraaijer
Description

The file @Systemdir & "\oobe\images\mslogo.jpg" does not exist in Windows Vista.

I've looked for an alternative image in the windows folder which is available for the other windows version but i haven't found one..

Note: See TracQuery for help on using queries.