E.25 Action - Registry Edit

The Action - Registry Edit dialog box lets you configure the registry settings to apply. We recommend that you back up the registry before applying the specified registry settings, and ensure that the registry is properly formatted and well tested.

Click the Registry Tree tab to select hives in the tree to which you want to add values and keys, rename or remove sections, or import a registry file. Click the Advanced Settings tab to specify how you want the action to run (as system or user) and to back up the registry file before applying the modified registry file.

You access this dialog box by using the following methods:

The following sections contain additional information:

E.25.1 Registry Tree

The Registry Tree page lets you select hives in the tree to which you want to add values and keys, rename or remove sections, or import a registry file.

Figure E-27 Action - Registry Edit Dialog Box: Registry Tree Page

The following table lists the tasks you can perform to manage registry tree changes.

Task

Steps

Add a registry key

  1. Select a registry hive, click New, then click Key.

  2. Specify the key’s name. For example, Software.

    You can also specify multiple levels of keys by separating them with a backslash (\). For example, Novell\ZENworks\Zfd.

    Do not use the forward slash (/) as a separator.

  3. Select one of the following registry operations:

    • Create Always: Creates the key regardless of whether the key currently exists in the workstation’s registry.

    • Create If Does Not Exist: Creates the key only if the key does not currently exist in the workstation’s registry.

    • Rename: Renames the key if it currently exists in the workstation’s registry.

    • Delete: Deletes the key if it currently exists in the workstation’s registry.

    • Delete and Recreate: Deletes the key if it currently exists in the workstation’s registry, then re-creates the key.

    • Delete if Empty: Deletes the key if it currently exists in the workstation’s registry and the key is empty.

    • None: Does not perform any registry operation.

Add a registry value

  1. Select the check box next to the desired item, then click Value to display the Add Value To dialog box.

  2. Select one of the following options from the Value Type list:

    • Default: Adds a default string value to the selected key.

    • String: Adds a string value to the selected key.

    • Binary: Adds a binary value to the selected key. Most hardware component information is stored as binary data and is displayed in hexadecimal format.

    • Dword: Adds a DWORD value to the selected key. DWORD values are represented by a number that is 4 bytes long. Many parameters for device drivers and services are this type and are displayed in binary, hexadecimal, or decimal format.

    • Expandable String: Adds an expandable-string value to the selected key. An expandable string is a variable-length data string. This data type includes variables that are resolved when a program or service uses the data.

    • Multiple String: Adds a multi-value string to the selected key. Multiple string values contain lists or multiple values in a form that people can read. Entries are separated by spaces, commas, or other marks.

    • Qword: Adds a Qword string to the selected key. A Qword value is data represented by a number that is a 64-bit integer. This data is displayed in the Registry Editor as a binary value.

    • Link: Adds a link string value to the selected key. A link string value is a Unicode string naming a symbolic link.

    • None: Does not perform any registry operation.

    • Full Resource Descriptor: Adds a full resource descriptor value to the selected key. A full resource descriptor is a series of nested arrays designed to store a resource list for a hardware component or driver.

    • Resource List: Adds a resource list to the selected key. A resource list is a series of nested arrays that is designed to store a resource list that is used by a hardware device driver or one of the physical devices it controls.

    • Resource Requirement List: Adds a resource requirements list to the selected key. A resource requirements list is a series of nested arrays designed to store a device driver's list of possible hardware resources that the driver or one of the physical devices it controls can use.

  3. Specify the data. Depending on which value type you selected in the previous step, the type of data varies.

  4. Select one of the following registry operations:

    • Create Always: The setting is always created in the registry, even if it already exists. If it exists, the setting's current values are overwritten. For example, if PATH=C:\ already exists, PATH=C:\TEMP replaces it.

    • Create If Exists: The setting is created only if it already exists. The setting's current values are overwritten. For example, if PATH=C:\ already exists, PATH=C:\TEMP replaces it.

    • Create If Does Not Exist: The setting is created only if it does not already exist.

    • Delete: The setting is deleted. If the registry setting has subordinate settings, the subordinate settings are also deleted.

    • Append If Exists, Otherwise Create: Appends the registry value if the value currently exists in the workstation’s registry. If the registry value does not exist, it is created.

      Prepend If Exists, Otherwise Create: Prepends the registry value if the value currently exists in the workstation’s registry. If the registry value does not exist, it is created.

Rename an entry

  1. Select the check box next to the desired item, then click Edit > Rename.

  2. Specify the new name.

Remove an entry

  1. Select the check box next to the desired item, then click Delete.

Import the contents of a registry file

  1. Click Import, then specify the registry file whose contents you want to import.

Search for a registry value name, registry key, or both.

  1. Specify the name of the value or key that you want to search for.

  2. Select Registry Key/Value, Registry Value Data, or Both.

  3. Select the Search within the selected nodes only check box to limit the search to the node you selected in the Registry Tree list.

  4. Click Search.

E.25.2 Advanced Settings

The Advanced Settings page lets you configure the registry settings to apply.

Figure E-28 Action - Registry Edit Dialog Box: Advanced Settings Page

Run Action As: Specify how you want the action to run:

  • System: The action is run under the Local System user and inherits Administrator-level credentials. For example, the action has full rights to the HKEY_LOCAL_MACHINE hive.

    Select the Apply HKEY_CURRENT_USER changes to the logged in user's hive instead of .DEFAULT option to enable the changes to be made in the user’s hive instead of the DEFAULT hive of HKEY_USERS.

  • User: The registry file is applied using the logged-in user’s credentials. For example, the action has the same rights to the registry and the file system as the logged-in user. If you are changing keys in the HKEY_CURRENT_USER hive, you must run the action as User. Depending on the rights assigned to the user, the action might or might not have rights to the HKEY_LOCAL_MACHINE hive. If you select User, the user must be logged in to the device or the action fails.

Take a Backup of the Registry Before Applying the Registry File: Select the check box, then specify the path to the backup file, for example, c:\BackupFile.reg.

If you select this option, the entire registry is backed up before importing the configured registry file. The backup process is performed every time this action executes. This can be a time-consuming operation and the backup file can be large.

Before you edit the registry, export the keys in the registry that you plan to edit, or back up the entire registry by selecting this option. If a problem occurs, you can then restore the registry to its previous state.