VBcoders Guest



Don't have an account yet? Register
 


Forgot Password?



Getting Charactersitics and Details of the System BIOS using Windows Management Instrumentation - F

by Raghu (22 Submissions)
Category: Windows System Services
Compatability: VB 6.0
Difficulty: Unknown Difficulty
Originally Published: Wed 3rd March 2004
Date Added: Mon 8th February 2021
Rating: (1 Votes)

Getting Charactersitics and Details of the System BIOS using Windows Management Instrumentation - For Windows 2000/Windows NT5/XP

API Declarations


'Code Sample for Getting the BIOS Characteristics
'Using WindoObjWmi Management Instrumentation

'Code Developed By: S.Raghunathan
'Email Id: [email protected]
'============================================
'Steps to Follow
'---------------
'Create a Form with a CommandButton,TextBox(Multiline) And a ListBox
'Name the CommandButton as Command1
'Name the TextBox as Text1
'Name the ListBox as List1
'and Copy the Code and Paste in the Coding Window and Run and Click
'the CommandButton


Dim Characteristics(40) As String
Dim bc() As String
Dim ObjWmi As Object
Dim ObjBiosCollection As Object
Dim ObjBios As Object
Dim Str1 As String


Rate Getting Charactersitics and Details of the System BIOS using Windows Management Instrumentation - F



Characteristics(0) = "Reserved"
Characteristics(1) = "Reserved"
Characteristics(2) = "Unknown"
Characteristics(3) = "BIOS Characteristics Not Supported"
Characteristics(4) = "ISA is supported"
Characteristics(5) = "MCA is supported"
Characteristics(6) = "EISA is supported"
Characteristics(7) = "PCI is supported"
Characteristics(8) = "PC Card (PCMCIA) is supported"
Characteristics(9) = "Plug and Play is supported"
Characteristics(10) = "APM is supported"
Characteristics(11) = "BIOS is Upgradeable (Flash)"
Characteristics(12) = "BIOS shadowing is allowed"
Characteristics(13) = "VL-VESA is supported"
Characteristics(14) = "ESCD support is available"
Characteristics(15) = "Boot from CD is supported"
Characteristics(16) = "Selectable Boot is supported"
Characteristics(17) = "BIOS ROM is socketed"
Characteristics(18) = "Boot From PC Card (PCMCIA) is supported"
Characteristics(19) = "EDD (Enhanced Disk Drive) Specification is supported"
Characteristics(20) = "Int 13h - Japanese Floppy for NEC 9800 1.2mb (3.5, 1k Bytes/Sector, 360 RPM) is supported"
Characteristics(21) = "Int 13h - Japanese Floppy for Toshiba 1.2mb (3.5, 360 RPM) is supported"
Characteristics(22) = "Int 13h - 5.25 / 360 KB Floppy Services are supported"
Characteristics(23) = "Int 13h - 5.25 /1.2MB Floppy Services are supported"
Characteristics(24) = "Int 13h - 3.5 / 720 KB Floppy Services are supported"
Characteristics(25) = "Int 13h - 3.5 / 2.88 MB Floppy Services are supported"
Characteristics(26) = "Int 5h, Print Screen Service is supported"
Characteristics(27) = "Int 9h, 8042 Keyboard services are supported"
Characteristics(28) = "Int 14h, Serial Services are supported"
Characteristics(29) = "Int 17h, printer services are supported"
Characteristics(30) = "Int 10h, CGA/Mono Video Services are supported"
Characteristics(31) = "NEC PC-98"
Characteristics(32) = "ACPI supported"
Characteristics(33) = "USB Legacy is supported"
Characteristics(34) = "AGP is supported"
Characteristics(35) = "I2O boot is supported"
Characteristics(36) = "LS-120 boot is supported"
Characteristics(37) = "ATAPI ZIP Drive boot is supported"
Characteristics(38) = "1394 boot is supported"
Characteristics(39) = "Smart Battery supported"
End Sub

Private Sub Command1_Click()

Set ObjWmi = GetObject("Winmgmts:")

Set ObjBiosCollection = ObjWmi.ExecQuery("SELECT Name,BiosCharacteristics,SMBIOSPresent,SMBIOSMajorVersion,SMBIOSMinorVersion,Version,SMBIOSBIOSVersion,ListOfLanguages,Description,CurrentLanguage,Manufacturer,Status FROM Win32_BIOS")

Str1 = "System BIOS Details : " & vbCrLf & "---------------------" & vbCrLf

For Each ObjBios In ObjBiosCollection

    For i = 0 To UBound(ObjBios.BiosCharacteristics) - 1
        List1.AddItem Characteristics(ObjBios.BiosCharacteristics(i))
    Next
    
    Str1 = Str1 & "Manufacturer" & vbTab & ":" & vbTab & ObjBios.Manufacturer & vbCrLf
    Str1 = Str1 & "Description" & vbTab & ":" & vbTab & ObjBios.Description & vbCrLf
    Str1 = Str1 & "Release Date" & vbTab & ":" & vbTab & Format(Left(ObjBios.Version, 8), "DD - mmmm - YYYY") & vbCrLf
    Str1 = Str1 & "Status" & vbTab & vbTab & ":" & vbTab & ObjBios.Status & vbCrLf
    Str1 = Str1 & "BIOS Version" & vbTab & ":" & vbTab & ObjBios.SMBIOSBIOSVersion & vbCrLf
    Str1 = Str1 & "Current Language" & vbTab & ":" & vbTab & ObjBios.CurrentLanguage & vbCrLf
    
    Str1 = Str1 & "----------------------------------------------------------" & vbCrLf
    Str1 = Str1 & "SM BIOS Present" & vbTab & vbTab & ":" & vbTab & ObjBios.SMBIOSPresent & vbCrLf
    Str1 = Str1 & "SM BIOS Major Version" & vbTab & ":" & vbTab & ObjBios.SMBIOSMinorVersion & vbCrLf
    Str1 = Str1 & "SM BIOS Minor Version" & vbTab & ":" & vbTab & ObjBios.SMBIOSMajorVersion & vbCrLf
    Str1 = Str1 & "----------------------------------------------------------" & vbCrLf
    
    For i = 1 To UBound(ObjBios.ListOfLanguages) - 1
        If Trim(ObjBios.ListOfLanguages(i)) <> vbNullString Then
            Str1 = Str1 & "BIOS Installable Languages" & vbTab & " : " & vbTab & ObjBios.ListOfLanguages(i) & vbCrLf
        End If
    Next
    
    Str1 = Str1 & "----------------------------------------------------------" & vbCrLf
Next

Text1 = Str1

End Sub

Download this snippet    Add to My Saved Code

Getting Charactersitics and Details of the System BIOS using Windows Management Instrumentation - F Comments

No comments have been posted about Getting Charactersitics and Details of the System BIOS using Windows Management Instrumentation - F. Why not be the first to post a comment about Getting Charactersitics and Details of the System BIOS using Windows Management Instrumentation - F.

Post your comment

Subject:
Message:
0/1000 characters