Here is one:
'32 or 64 bit
On Error Resume Next
Set WshShell = WScript.CreateObject("WScript.Shell")
sMsg = "This script will Display if you are running Windows 32 or 64 bit." &
vbCr _
& "It will also Display the date and time the OS was installed and the OS
version." & vbCr & vbCr _
& "Would you like to continue?"
sInput = MsgBox(sMsg, vbYesNo + vbInformation, "Paul's XP and Vista Tweaks")
If sInput = vbYes Then
X = WshShell.RegRead("HKLM\SYSTEM\CurrentControlSet\Control\Session
Manager\Environment\PROCESSOR_ARCHITECTURE")
If X = "x86" Then
MsgBox "You Are Running Windows 32-bit!" & vbCr & "This script was
downloaded from www.paulsxp.com", 64, "Windows 32-bit or 64-bit"
Else
MsgBox "You Are Running Windows XP 64-bit" & vbCr & "This script was
downloaded from www.paulsxp.com", 64, "Good for You!"
End If
For Each pm in GetObject("winmgmts:{impersonationLevel=impersonate}")._
ExecQuery("Select CurrentTimeZone, InstallDate From
Win32_OperatingSystem")
With CreateObject("WbemScripting.SWbemDateTime")
.Value = pm.InstallDate
MsgBox "Windows Installed: " & DateAdd("n", -pm.CurrentTimeZone,
..GetVarDate) & vbCr &_
"This script was downloaded from www.paulsxp.com" ,64, "XP Installed"
WshShell.Run("winver.exe")
End With
Next
End If
"kp" <kiran.r.pillai@xxxxxx> wrote in message
news:4a48ec64-d26d-487b-9bfd-b89f746da786@xxxxxx
> On Apr 24, 5:38 pm, dinesh <gu...@xxxxxx-email.com> wrote:
>> Type *winver *in the run box. OR simply hold the windows logo
>> key+pause/break key.
>>
>> --
>> dinesh
>>
>> Dinesh is a glorious beacon of light - Says Google. >
> Hi Dinesh,
>
> If you observe my question is how to find out the bit-ness through a
> vb script. I was already aware of the "winver" command. But, I guess I
> won't be able to run winver through a vb script and parse the output.
> Let me know if my understanding is incorrect here.
>
> Regards,
> Kiran