RegCreateKeyEx function advapi32
WIN32_ERROR
RegCreateKeyEx(
- HKEY hKey,
- PCWSTR lpSubKey,
- PCWSTR? lpClass,
- REG_OPEN_CREATE_OPTIONS dwOptions,
- REG_SAM_FLAGS samDesired,
- Pointer<
SECURITY_ATTRIBUTES> ? lpSecurityAttributes, - Pointer<
Pointer< phkResult,NativeType> > - Pointer<
Uint32> ? lpdwDisposition,
Creates the specified registry key.
If the key already exists, the function opens it. Note that key names are not case sensitive.
To learn more, see learn.microsoft.com/windows/win32/api/winreg/nf-winreg-regcreatekeyexw.
Implementation
@pragma('vm:prefer-inline')
WIN32_ERROR RegCreateKeyEx(
HKEY hKey,
PCWSTR lpSubKey,
PCWSTR? lpClass,
REG_OPEN_CREATE_OPTIONS dwOptions,
REG_SAM_FLAGS samDesired,
Pointer<SECURITY_ATTRIBUTES>? lpSecurityAttributes,
Pointer<Pointer> phkResult,
Pointer<Uint32>? lpdwDisposition,
) => WIN32_ERROR(
_RegCreateKeyEx(
hKey,
lpSubKey,
NULL,
lpClass ?? nullptr,
dwOptions,
samDesired,
lpSecurityAttributes ?? nullptr,
phkResult,
lpdwDisposition ?? nullptr,
),
);