Retrive the Vendor Infromation of the Processor

Using the Registry and Registry Key classes in Microsoft.Win32, we can easily access the registry.
The following is a sample code that reads a key and displays the value:


using System;
using Microsoft.Win32;

class regTest
{
public static void Main(String[] args)
{
RegistryKey regKey;
Object value;
regKey = Registry.LocalMachine;
regKey = regKey.OpenSubKey("HARDWARE\\DESCRIPTION\\System\\CentralProcessor\\0");
value = regKey.GetValue("VendorIdentifier");
Console.WriteLine("The central processor of this machine is: {0}.", value);
}
}





By
Nathan


Comments

Author: Umesh Bhosale03 Apr 2014 Member Level: Silver   Points : 0

Nice Article



  • Do not include your name, "with regards" etc in the comment. Write detailed comment, relevant to the topic.
  • No HTML formatting and links to other web sites are allowed.
  • This is a strictly moderated site. Absolutely no spam allowed.
  • Name:
    Email: