We are usually on the registry of the modifications are mostly by using Registry Editor Regedit to achieve, but one day, you are logged in a website, they would find the registry editor has been banned, how do? The easiest and most convenient way does not require any tools that use the REG file to remove restrictions on the Registry Editor.
What is a REG file
REG file is actually a registry script file, double-click the REG file to which data can be imported into the registry. REG file that can be used directly to make any modifications to the registry, it can be exempted from the operation of the registry registry editor disabled limitations, more powerful, flexible, and the other, as REG files can use any text file editing tools (such as Notepad) to modify, so the data through its registry modifications, if an error occurs, you can also change back to the REG file and then import the data, in order to achieve recovery operations, so it than the direct use Registry Editor to modify more secure, so master the use of REG files can sometimes play a multiplier, an unexpected effect.
Create a REG file
REG file to create a very simple text file can be edited by any tools to achieve. We can remove the registry to create a REG file to disable restricted restore.reg example to introduce the specific process.
Open Notepad, the file in Notepad, enter the following:
[HKEY_CURRENT_USER \ Software \ Microsoft \ Windows \ CurrentVersion \ Policies \ System] "DisableRegistryTools" = dword: 00000000
Save this file, open the "Save As" dialog box, select a good save path, and then click the "Save as type" drop-down arrow to select "All Files" (be sure to select this step, otherwise the file will be saved automatic with TXT extension), then in the "File Name" enter "restore.reg" and press "Save" button (Figure 1). After this you can double-click Disable registry restore.reg to directly lift the restrictions.
REG file to be modified for
REG file that we use to operate the registry when the object to be manipulated, there are two: one is the master key to operate, one is the primary key of the key projects under operation. The operation of the primary key have to add, delete two, while the operation is divided into key projects to add, modify, and delete three. Here we have a one to achieve.
1, the operation of the primary key
(1) Add the primary key
To use the REG file in the registry to add a primary key is very convenient, just body parts directly to the file "" written on the form to add the primary key path.
For example: HKEY_LOCAL_MACHINE \ Software to add a primary key named "Oncidium software studio," the primary key, as follows:
[HKEY_LOCAL_MACHINE \ Software \ Oncidium Software Studio]
Figure 1 to create, save reg file
(2) Remove the primary key
Use the REG file in the registry to delete a primary key, body parts in the file "" enclose the path in front of the primary key with a "-" sign to delete the primary key operation to remove the primary key will be for all children under keys and key projects, so this is a more dangerous commands, use the utmost attention. For example, to add that we just delete the primary key, as follows:
[-HKEY_LOCAL_MACHINE \ Software \ Oncidium Software Studio]
2, the operation of key projects
(1) Add key project
Add key projects operating in the Registry Editor as "New" command, in general, divided into three key types of data: string value, binary value, and DWORD Value. In the REG file to add the key we have to set the data type of the project, if you want to add a string value, then the "=" sign behind the English use double quotes data; if you add a DWORD type value, "= "was behind the format" dword: data "; If you add a binary value," = "sign behind was" hex: data. " To set the default value of key data, "=" sign in front of key name should be "@" symbol, and no double quotes.
For example, we want to "HKEY_LOCAL_MACHINE \ Software \ Oncidium Software Studio" under the main key to set the default key for "Oncidium studio", and were added to the "name" key items (string value), "age" key project (binary value), "marital status" key project (DWORD value). Corresponding REG file as follows:
[HKEY_LOCAL_MACHINE \ Software \ Oncidium Software Studio]
@ = "Oncidium Studio"
"Name" = "Xu Haibin"
"Age" = hex: 23
"Marital status" = dword: 00000000
Add a key item, if the primary key where the key path does not exist, while adding key projects will automatically create the primary key. Also add a string value in key project areas is also worth noting that when the string value is a string value, including file path, the path separator applications, "\ \" double slash to show and primary key in the registry path separator to distinguish. For example, we want to register in the "HKEY_LOCAL_MACHINE \ Software \ Microsoft \ Windows \ CurrentVersion \
Run "under the main key to start the group added in the" C: \ PROGRAM FILES \ BOOBSOFT \ screen saver controller "directory of an application under the" Screen saver controller. Exe "start key projects, REG files as follows:
[HKEY_LOCAL_MACHINE \ Software \ Microsoft \ Windows \ CurrentVersion \ Run]
"Scr" = "C: \ \ PROGRAM ILES \ \ BOOBSOFT \ \ screen saver controller \ \ screen saver control. Exe"
(2) modify the key project
In fact, very similar to the changes and additions for existing key projects, we have to modify its data, just to give the correct data to the corresponding key projects, new error data will automatically overwrite the old data, for example, When some of the malicious Web page to modify your IE title bar text, the title bar is always displayed in the ad text that site, very annoying, we know that modify IE title bar text through the "HKEY_CURRENT_USER \ Software \
Figure 2 IR title bar of the corresponding registry key values
Microsoft \ Internet Explorer \ Main "under the master key" Window Title "(Figure 2) key data set, then we can through the REG file back to the default IE title bar text.
[HKEY_CURRENT_USER \ Software \ Microsoft \ Internet Explorer \ Main]
"Window Title" = ""
(3) delete the key project
REG file with the delete key project is also very convenient, and remove the primary key is similar, but also by the "=" to achieve, but this is not added to the front, but the "-" symbol on the key projects of the equal sign behind. For example, some malicious Web page to modify IE title bar in such settings also changes the start menu items associated with key data, making the start menu "Run", "seek", "close" command is gone, into the following This REG file to delete the corresponding key item in the Start menu after you can retrieve these commands.
[HKEY_CURRENT_USER \ Software \ Microsoft \ Windows \ CurrentVersion \ Policies \ Explorer]
"NoRun" =- (remove the "Run" command)
"NoClose" =- (back, "shutdown" command)
"NoFind" =- (back, "Find" command)
Know how to create a REG file and through the REG file to add, modify, delete, and this time we look at how the REG file to which the data is imported into the registry of.
Figure 1 confirmation box
When we double-click the REG file, the system will first prompt. "Really should XXX.REG added to the registry information within it?" Inquiry dialog box (Figure 1), click "Yes" button, the system will be in accordance with REG operation described in the document to modify the registry, is completed and will give prompt "XXX.REG the information has been successfully entered into the registry," the information in the REG file into the registry of the operation known as "merger."
Figure 2 In this REG file to modify the default command
Modify the default values
In the REG file, right-click, there are three commands on the REG file: Merge, Print, Edit, in bold is the "merge" operation, which is the default open mode, that is, double-click to perform the operation. If you do not want to perform double-click the REG file, "merge" operation, you can change the way it's turned on by default "Edit." Open Windows Explorer, click the "View" menu in the "Folder Options" command in the Open dialog box, click "File Types" tab, then "Registered file types" list, locate and select the "registry entries" (Figure 2), from the following "Open With" we can see that: the original REG file the default "merge" operation is associated with the Registry Editor Regedit it! then click the "Edit" button , open the "Edit File Type" dialog box, then select "action" list "Edit", then click the "Make Default" button (Figure 3), after double-click the REG file to open it with Notepad editing.
Figure 3 REG command set to edit the default
Here I tell you the way a unique stunts, if you want to import REG files without any prompt, you can see in Figure 4 shows the dialog box, select "merge", then click the "Edit" button in the pop-up dialog box the command line, type "regedit.exe / s"% 1 "" can, which is using the Registry Editor Regedit to import a model known as the quiet hidden parameter "/ S", if you import REG files add "/ S" parameter, the system will not pop up any dialog box prompts directly imported.
Figure 4 confirm the cancellation of import
Sometimes on some computers set up to disable the Registry Editor, in order to prevent some computer expert to use REG files (read this article you can also become a master ^ _ ^) to lift restrictions on the Registry Editor will Open the REG file to the default settings for other unrelated programs, of course, then you can modify the "Folder Options" in the related settings to change back, but there is a more absolute way to make REG file can not use the system default way open.
Figure 5 Open the file selection REG
Run the registry editor, the "HKEY_CLASSES_ROOT.reg" under the default value to "txtfile", then open the way REG files point to the TXT files. Such changes do not know even if modified "folder type" in the "registry entries" setting can not change back, of course, then the system has disabled the Registry Editor, you can not modify the Registry Editor . However, after the author's research found that there is a way to break this to disable REG file. We can hold on the REG file edited "Shift" key while clicking the right mouse button, then the system will let you re-select Open, select from using Registry Editor Regedit to open (Figure 5) can be REG file into the registry.