Dela via


CRegKey Members

Methods

Attach

Call this method to attach an HKEY to the CRegKey object by setting the m_hKey member handle to hKey.

Close

Call this method to release the m_hKey member handle and set it to NULL.

Create

Call this method to create the specified key, if it does not exist as a subkey of hKeyParent.

CRegKey

The constructor.

~CRegKey

The destructor.

DeleteSubKey

Call this method to remove the specified key from the registry.

DeleteValue

Call this method to remove a value field from m_hKey.

Detach

Call this method to detach the m_hKey member handle from the CRegKey object and set m_hKey to NULL.

EnumKey

Call this method to enumerate the subkeys of the open registry key.

Flush

Call this method to write all of the attributes of the open registry key into the registry.

GetKeySecurity

Call this method to retrieve a copy of the security descriptor protecting the open registry key.

NotifyChangeKeyValue

This method notifies the caller about changes to the attributes or contents of the open registry key.

Open

Call this method to open the specified key and set m_hKey to the handle of this key.

QueryBinaryValue

Call this method to retrieve the binary data for a specified value name.

QueryDWORDValue

Call this method to retrieve the DWORD data for a specified value name.

QueryGUIDValue

Call this method to retrieve the GUID data for a specified value name.

QueryMultiStringValue

Call this method to retrieve the multistring data for a specified value name.

QueryQWORDValue

Call this method to retrieve the QWORD data for a specified value name.

QueryStringValue

Call this method to retrieve the string data for a specified value name.

QueryValue

Call this method to retrieve the data for the specified value field of m_hKey. Earlier versions of this method are no longer supported and are marked as ATL_DEPRECATED.

RecurseDeleteKey

Call this method to remove the specified key from the registry and explicitly remove any subkeys.

SetBinaryValue

Call this method to set the binary value of the registry key.

SetDWORDValue

Call this method to set the DWORD value of the registry key.

SetGUIDValue

Call this method to set the GUID value of the registry key.

SetKeySecurity

Call this method to set the security of the registry key.

SetKeyValue

Call this method to store data in a specified value field of a specified key.

SetMultiStringValue

Call this method to set the multistring value of the registry key.

SetQWORDValue

Call this method to set the QWORD value of the registry key.

SetStringValue

Call this method to set the string value of the registry key.

SetValue

Call this method to store data in the specified value field of m_hKey. Earlier versions of this method are no longer supported and are marked as ATL_DEPRECATED.

Operators

operator HKEY

Converts a CRegKey object to an HKEY.

operator =

Assignment operator.

Data Members

m_hKey

Contains a handle of the registry key associated with the CRegKey object.

m_pTM

Pointer to CAtlTransactionManager object

Static Functions

SetValue

Call this method to store data in the specified value field of m_hKey. Earlier versions of this method are no longer supported and are marked as ATL_DEPRECATED.

See Also

Reference

CRegKey Class