DEV Community

Cover image for Let's add a key value to the Windows 10 registry
KenjiDoom
KenjiDoom

Posted on

Let's add a key value to the Windows 10 registry

The registry is a database of information that contains, user passwords, windows, and hardware settings. A key value contains settings specific to a program, these include its location and version.

There are 5 root keys, known also as a HIVE, that a tech should be aware of, these are the following, ROOT, USER, MACHINE, USERS, and CONFIG.
Keys

HKEY_CLASS_ROOT
Contains information about file extensions, and registered applications such as OLE. Settings that are specific to the local computer.

HKEY_CURRENT_USER
Contains information about the user who is currently logged in to the Windows machine.

HKEY_LOCAL_MACHINE
Stores information about hardware and software settings, specific to the local computer. This information used by all users that login on to the computer.

HKEY_USERS
Holds information about all the users who are actively loaded on the local machine, includes generic and user-specific information.

HKEY_CURRENT_CONFIG
HKEY_CURRENT_CONFIG is a shortcut to HKEY_LOCAL_MACHINE, but this contains information about the hardware attached to the computer.

You can also view the keys in their binary format in the following file location
This PC -> Local Disk (C:) -> Windows -> System32 -> config
binary files

Now allows us to begin creating a new sub-key by simply opening regedit.exe using run (Windows + R).
run command

Once Registry Editor opens, click on HKEY_LOCAL_MACHINE
machine
Then select the SOFTWARE, scroll down until you find the Microsoft tab
Microsoft
Once again, scroll down until you find Windows → Current Version -> Run
Windows found
Run
Hover over Run with the mouse, right-click mouse button, once the menu pops up, select new -> key, specify a name for the new key. I will call mine Kenji
Kenji
after hover over the blank space, right-click the mouse button again and select new -> key
new key
Provide a key value name.
kenjihere
That's it! That's how you create a new key value. Now, most of the time you'll be inputting values from a manual to solve a problem. This was a little guide to show, how one would go about doing it.

Thanks for reading!
Kenji

Top comments (0)