Registry Class
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Provides RegistryKey objects that represent the root keys in the Windows registry, and static
methods to access key/value pairs.
public ref class Registry abstract sealed
public ref class Registry sealed
public static class Registry
public sealed class Registry
[System.Runtime.InteropServices.ComVisible(true)]
public static class Registry
type Registry = class
[<System.Runtime.InteropServices.ComVisible(true)>]
type Registry = class
Public Class Registry
Public NotInheritable Class Registry
- Inheritance
-
Registry
- Attributes
Remarks
For more information about this API, see Microsoft.Win32.Registry class.
Fields
ClassesRoot |
Defines the types (or classes) of documents and the properties associated with those types. This field reads the Windows registry base key HKEY_CLASSES_ROOT. |
CurrentConfig |
Contains configuration information pertaining to the hardware that is not specific to the user. This field reads the Windows registry base key HKEY_CURRENT_CONFIG. |
CurrentUser |
Contains information about the current user preferences. This field reads the Windows registry base key HKEY_CURRENT_USER. |
DynData |
Obsolete.
Contains dynamic registry data. This field reads the Windows registry base key HKEY_DYN_DATA. |
LocalMachine |
Contains the configuration data for the local machine. This field reads the Windows registry base key HKEY_LOCAL_MACHINE. |
PerformanceData |
Contains performance information for software components. This field reads the Windows registry base key HKEY_PERFORMANCE_DATA. |
Users |
Contains information about the default user configuration. This field reads the Windows registry base key HKEY_USERS. |
Methods
GetValue(String, String, Object) |
Retrieves the value associated with the specified name, in the specified registry key. If the name is not found in the specified key, returns a default value that you provide, or |
SetValue(String, String, Object, RegistryValueKind) |
Sets the name/value pair on the specified registry key, using the specified registry data type. If the specified key does not exist, it is created. |
SetValue(String, String, Object) |
Sets the specified name/value pair on the specified registry key. If the specified key does not exist, it is created. |