Najprv:
Kód:
RegCreateKey(
HKEY hKey, // handle to an open key
LPCTSTR lpSubKey, // address of name of subkey to open
PHKEY phkResult // address of buffer for opened handle
);
a potom:
Kód:
LONG RegSetValue(
HKEY hKey, // handle to key to set value for
LPCTSTR lpSubKey, // address of subkey name
DWORD dwType, // type of value
LPCTSTR lpData, // address of value data
DWORD cbData // size of value data
);