Visual Basic.NET
  Home arrow Visual Basic.NET arrow Page 3 - Getting Hardware Information Using Visual ...
ASP Free Forums 
.NET  
ASP  
ASP Code  
ASP.NET  
ASP.NET Code  
BrainDump  
C#  
Code Examples  
Database  
Database Code  
IIS  
Microsoft Access  
MS SQL Server  
Visual Basic.NET  
Windows Scripting  
Windows Security  
XML  
ASP Web Hosting  
ASP.NET Web Hosting 
Dedicated Servers 
Actuate Whitepapers 
Moblin 
Windows Web Hosting
 
IBM® developerWorks 
Sun Developer Network 
Weekly Newsletter
 
Developer Updates  
Free Website Content 
 RSS  Articles
 RSS  Forums
 RSS  All Feeds
Write For Us Get Paid 
Request Media Kit
Contact Us 
Site Map 
Privacy Policy 
Support 
 USERNAME
 
 PASSWORD
 
 
  >>> SIGN UP!  
  Lost Password? 
VISUAL BASIC.NET

Getting Hardware Information Using Visual Basic.NET and VBScript
By: Jagadish Chaterjee
  • Search For More Articles!
  • Disclaimer
  • Author Terms
  • Rating: 5 stars5 stars5 stars5 stars5 stars / 16
    2006-01-25

    Table of Contents:
  • Getting Hardware Information Using Visual Basic.NET and VBScript
  • The class Win32 OnBoardDevice in detail
  • The class Win32_Processor in detail
  • Digging further into the motherboard's details

  • Rate this Article: Poor Best 
      ADD THIS ARTICLE TO:
      Del.ici.ous Digg
      Blink Simpy
      Google Spurl
      Y! MyWeb Furl
    Email Me Similar Content When Posted
    Add Developer Shed Article Feed To Your Site
    Email Article To Friend
    Print Version Of Article
    PDF Version Of Article
     
     
    ADVERTISEMENT

    Stay one step ahead of the competition. Evaluate and give feedback on some of the hottest web development tools on the market today. Make your opinion heard! Click Here

    Getting Hardware Information Using Visual Basic.NET and VBScript - The class Win32_Processor in detail


    (Page 3 of 4 )

    In the previous section, plenty of properties are available to retrieve information about processors. But I included only the most important properties from the existing WMI class (Win32_Processor); had I done otherwise, it would have made the program too long.

    The above program would list the information related to the properties of availability, Caption, CPUStatus, CurrentClockSpeed, DeviceID, Level, Name, ProcessorID, ProcessorType and SystemName. By using these properties, you can already retrieve plenty of information about the processors. You can further extend the above program with several other properties available in the “Win32_Processor” class. You can even refer to MSDN online for further properties.

    Let us go through these properties to understand them better.

    Availability: This property gives you the status of the processor's “availability.” The value, along with the description (I've included the most important ones) could be something like the following:

    Value

    Meaning

    1

    0x1

    Other

    2

    0x2

    Unknown

    3

    0x3

    Running/Full Power

    4

    0x4

    Warning

    5

    0x5

    In Test

    6

    0x6

    Not Applicable

    7

    0x7

    Power Off

    8

    0x8

    Off Line

    9

    0x9

    Off Duty

    10

    0xA

    Degraded

    11

    0xB

    Not Installed

    12

    0xC

    Install Error

    Caption: This property gives a short description of an object.

    CPUStatus: This property gives you the current status of the processor. The status changes indicate processor usage, not the physical condition of the processor. The following table shows you the status of the processor:

    Value

    Meaning

    0

    Unknown

    1

    CPU Enabled

    2

    CPU Disabled by User via BIOS Setup

    3

    CPU Disabled by User via BIOS (POST Error)

    4

    CPU is Idle

    5

    Reserved

    6

    Reserved

    7

    Other

    CurrentClockSpeed: This property shows you the current speed of the processor in MHz.

    DeviceID: This property gives you the unique identifier of a processor on the system.

    Level: This property gives you a definition of the processor type. The value depends on the architecture of the processor.

    Name: This property explains the label by which the object is known. When this property is a subclass, it can be overridden to be a key property.

    ProcessorID: This property provides us processor information that describes the processor's features.

    ProcessorType: This property gives you the type of processor available in your system.

    Value

    Meaning

    1

    Other

    2

    Unknown

    3

    Central Processor

    4

    Math Processor

    5

    DSP Processor

    6

    Video Processor

    System Name: This property gives you the name of your system (or the one to which you're connected).

    More Visual Basic.NET Articles
    More By Jagadish Chaterjee


       · Hello guys, another interesting article on WMI with VB.NET and VBScript. Enjoy and...
       · The articles do not give the code for addONBoardDevices and addProcessorDevice ....
       · Hi, I already provided the code in the downloadable. Please download the zip...
     

    VISUAL BASIC.NET ARTICLES

    - Movement and Player Statistics in a VB.NET T...
    - Creating and Drawing a Game Map in VB.NET
    - Working with Classes and Properties for Game...
    - Working with Loops, Arrays, and Collections ...
    - Learning Loops in VB.NET for Game Development
    - Learning VB.NET: Working with Variables, Con...
    - The Basics of VB.NET Through Text Game Devel...
    - Learning VB.NET Through Text Game Development
    - Types of Operators in Visual Basic
    - Operators
    - Understanding Custom Events using Visual Bas...
    - Polymorphism using Abstract Classes in Visua...
    - Shadowing using Shadows in Visual Basic.NET ...
    - Overloading and Overriding in Visual Basic.N...
    - More on Controlling Windows Fax Services Usi...




    © 2003-2008 by Developer Shed. All rights reserved. DS Cluster 2 hosted by Hostway