con questo script vedi il software installato in remoto
basta cambiare il valore di strComputer
codice:
Const HKLM = &H80000002 'HKEY_LOCAL_MACHINE
strComputer = ""
Set objExcel = CreateObject("Excel.Application")
objExcel.Workbooks.Add
strKey = "SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\"
strEntry1a = "DisplayName"
dim s
s = ""
Set objReg = GetObject("winmgmts:{impersonationLevel=impersonate}!\\" & strComputer & "/root/default:StdRegProv")
objReg.EnumKey HKLM, strKey, arrSubkeys
For Each strSubkey In arrSubkeys
intRet1 = objReg.GetStringValue(HKLM, strKey & strSubkey, strEntry1a, strValue1)
If intRet1 <> 0 Then
objReg.GetStringValue HKLM, strKey & strSubkey, strEntry1b, strValue1
End If
If strValue1 <> "" and left(strValue1,13) <> "Aggiornamento" Then
s= s & "," & strValue1
End If
objReg.GetStringValue HKLM, strKey & strSubkey, strEntry2, strValue2
If strValue2 <> "" Then
s= s & ", Install Date: " & strValue2
End If
objReg.GetDWORDValue HKLM, strKey & strSubkey, strEntry3, intValue3
objReg.GetDWORDValue HKLM, strKey & strSubkey, strEntry4, intValue4
If intValue3 <> "" Then
s= s & ", Version: " & intValue3 & "." & intValue4
End If
objReg.GetDWORDValue HKLM, strKey & strSubkey, strEntry5, intValue5
If intValue5 <> "" Then
s= s & ", Estimated Size: " & Round(intValue5/1024, 3) & " megabytes"
End If
Next
g_strSP2 = Split(s, ",")
For Each strSP2 In g_strSP2
objExcel.Cells(X, 1).Value = strComputer
objExcel.Cells(X, 2).Value = strSP2
X = X + 1
Next
Set objWorkbook = objExcel.ActiveWorkbook
objWorkbook.Saveas "C:\inventario.xls"
objWorkbook.Close
objExcel.Quit
salvalo come .vbs