System.Win.Registry.TRegistry.RootKey

From RAD Studio API Documentation
Jump to: navigation, search

Delphi

property RootKey: HKEY read FRootKey write SetRootKey;

C++

__property HKEY RootKey = {read=FRootKey, write=SetRootKey, nodefault};

Properties

Type Visibility Source Unit Parent
property public
System.Win.Registry.pas
System.Win.Registry.hpp
System.Win.Registry TRegistry

Description

Specifies the root key for the TRegistry object in an application.

Use RootKey to determine the hierarchy of subkeys an application can access, or to specify the root key for the application.

By default, RootKey is set to HKEY_CURRENT_USER when the registry object is created. To change the root key, specify a valid integer value for the RootKey property.

Note: For some operations, such as LoadKey or RegistryConnect, an application may need to change the default value of RootKey.

See Also

Code Examples