Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
How to read the BIOS number?
Message
General information
Forum:
Visual FoxPro
Category:
Windows API functions
Miscellaneous
Thread ID:
01019447
Message ID:
01019468
Views:
22
A slight correction to your code.
The line should read loWMIService = loLocator.ConnectServer()

>Juan,
>
>If you have Windows NT 4 SP 4 or later, you can use WMI like this:
>
>
>local loWMI, loItems, loItem, loLocator
>
>loLocator		= CREATEOBJECT('WBEMScripting.SWBEMLocator')
>loWMI			= loLocator.ConnectServer()
>loItems			= loWMIService.ExecQuery("Select * from Win32_BIOS where PrimaryBIOS = TRUE")
>
>For Each loItem in loItems
>    ? "Caption: " , loItem.Caption
>    ? "CurrentLanguage: " , loItem.CurrentLanguage
>    ? "Description: " , loItem.Description
>    ? "Manufacturer: " , loItem.Manufacturer
>    ? "Name: " , loItem.Name
>    ? "ReleaseDate: " , loItem.ReleaseDate
>    ? "SerialNumber: " , loItem.SerialNumber
>    ? "SMBIOSBIOSVersion: " , loItem.SMBIOSBIOSVersion
>    ? "SMBIOSMajorVersion: " , loItem.SMBIOSMajorVersion
>    ? "SMBIOSMinorVersion: " , loItem.SMBIOSMinorVersion
>    ? "SMBIOSPresent: " , loItem.SMBIOSPresent
>    ? "Status: " , loItem.Status
>    ? "Version: " , loItem.Version
>Next
>
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform