Sub_Zero Posted September 9, 2006 Report Posted September 9, 2006 Heres a Tutorial on the Registry. The Tutorial is Broken down into 3 sections. 1)Little Background on the Registry. 2)Adding values to the registry. 3)Deleting Keys and Values. ------------------------------------------------------------------------------------------------------- 1) ****Little Background on the Registry.**** The Registry is basically a database used to store Information,Settings and Options. It contains everything from settings of all the Hardware, Software and Users. The registry is mainly made up of the similar directory structure made of on your hard disk. Each branch is called a Hive. Now inside the Hive there lies Key's. Now within the Key there are values of course. There are really three main types of values. 1)String 2)Binary 3)DWORD I will go into more detail about them further on in the tutorial. Now you might be saying to your self? What are Branches? Branches are shown as a Folder Icon in the registry with the Branches name to the right of it. There are 5 main branches in Windows XP and 2000 each with a portion of information which make up the registry. 1)HKEY_CLASSES_ROOT: This branch has all the file types on your computer. 2)HKEY_CURRENT_USER: This branch links to the section of HKEY_USERS appropriate for the user currently logged onto the Computer. 3)HKEY_LOCAL_MACHINE: This branch contains the Computer's specific information about the type of hardware, software, and other preferences on the Computer. 4)HKEY_USERS: This contains certain prefernces for each of the user at the Computer. 5)HKEY_CURRENT_CONFIG: This branches to the HKEY_LOCAL_MACHINE for current hardware configuration. Now onto the Values of the Registry but more in depth this time. 1)REG_BINARY: This type stores the value as raw binary data. 2)REG_DWORD: This type represents the data by a four byte number and is commonly used for boolean values such as "0" to disable and "1" for enabling. Like a Light Switch, Up to put light on and down to put light off. 3)REG_SZ: This type is a standard string used to represent human readable text values. Also there are REG_EXPAND_SZ and REG_MULTI_SZ. 2) ****Adding values to the registry.**** Now enough of just explaining the registry lets do something with the registry. Firstly you will need Notepad. Im sure everyones got that. My First Example is going to input "Hello" on the top Bar of Internet Explorer. Now to input the commands. <--------------Starting Commands--------------> REGEDIT4 [HKEY_CURRENT_USERSoftwareMicrosoftInternet ExplorerMain] "Window Title"="Hello" <--------------End of Commands--------------> Now I Will explain this to you. The line "[HKEY_CURRENT_USERSoftwareMicrosoftInternet ExplorerMain]" means that Your little reg file will look for that location in the registry. The line "Window Title"="Hello" Now all this does is make a new String Value "Window Title" and in that Key the Data is "Hello" Pretty simple isnt it. Now just save this as a .reg file and run it. Now these commands have only been tested on Windows XP it might be a different location in other Versions of Windows. Now go check if it has worked. This is how you can add things to the registry or change things to the registry. 3) ****Deleting Keys and Values.**** Now to delete a whole Key from the registry do the same as I told you above but with different commands. <--------------Starting Commands--------------> REGEDIT4 [-HKEY_CURRENT_USERSoftwareMicrosoftInternet ExplorerMain] <--------------End of Commands--------------> Now I dont reccomend doing that if you use Internet Explorer. But as you can see all we done is place a "-" sign in front of the Branch. Now to delete Individual Keys like the one we made for Internet Explorer is as followed. <--------------Starting Commands--------------> REGEDIT4 [HKEY_CURRENT_USERSoftwareMicrosoftInternet ExplorerMain] "Window Title"=- <--------------End of Commands--------------> Now as you can see we have specified the branch and location. Then we have placed the Value's name and put a "-" sign to it so it deletes whats inside that value. Hope this helps you understand abit about the registry. With Regards... Bharath Quote