RegReplaceKey function advapi32
Replaces the file backing a registry key and all its subkeys with another file, so that when the system is next started, the key and subkeys will have the values stored in the new file.
To learn more, see learn.microsoft.com/windows/win32/api/winreg/nf-winreg-regreplacekeyw.
Implementation
@pragma('vm:prefer-inline')
WIN32_ERROR RegReplaceKey(
HKEY hKey,
PCWSTR? lpSubKey,
PCWSTR lpNewFile,
PCWSTR lpOldFile,
) => WIN32_ERROR(
_RegReplaceKey(hKey, lpSubKey ?? nullptr, lpNewFile, lpOldFile),
);