http://dieseyer.de • all rights reserved • © 2011 v11.4
'v7.A**********************************************************
' File: winversp-regread.vbs
' Autor: dieseyer@gmx.de
' dieseyer.de
'
' Programm ermittelt WindowsNT-Version und Sp-Version
'**************************************************************
Option Explicit
Dim Txt
Dim fso : Set fso = WScript.CreateObject("Scripting.FileSystemObject")
Dim WSHShell : Set WSHShell = WScript.CreateObject("WScript.Shell")
Dim WSHNet : Set WSHNet = WScript.CreateObject("WScript.Network")
Dim oArgs : Set oArgs = Wscript.Arguments
Const KeyX = "HKLM\Software\Microsoft\Windows NT\CurrentVersion\"
' On Error Resume Next
Txt = Txt & vbCRLF & "ProductName: " & vbTab & vbTab & WSHShell.RegRead( KeyX & "ProductName" )
Txt = Txt & vbCRLF & "CSDVersion: " & vbTab & vbTab & WSHShell.RegRead( KeyX & "CSDVersion" )
Txt = Txt & vbCRLF & "CurrentVersion: " & vbTab & vbTab & WSHShell.RegRead( KeyX & "CurrentVersion" )
Txt = Txt & vbCRLF & "CurrentBuildNumber: " & vbTab & WSHShell.RegRead( KeyX & "CurrentBuildNumber" )
Txt = Txt & vbCRLF & "BuildLab: " & vbTab & vbTab & vbTab & WSHShell.RegRead( KeyX & "BuildLab" )
On Error GoTo 0
MsgBox Txt
http://dieseyer.de • all rights reserved • © 2011 v11.4