I have a trouble writing some keys into registry:
PHKEY key = NULL; HRESULT hResult = S_FALSE;
hResult = RegOpenKeyEx(HKEY_CLASSES_ROOT, _T("AppID"), 0, KEY_CREATE_SUB_KEY, key);
and this fails with code 0x00000057 - The parameter is incorrect.
hResult = RegCreateKeyEx(HKEY_CLASSES_ROOT, _T("new_key_name"), 0, NULL,
REG_OPTION_NON_VOLATILE, KEY_WRITE, NULL, key, NULL);
this fails with code 0x000003f2 - The configuration registry key is invalid.
I have also tried some variations, but the result is always the same. I was using this functions before and never had a problem. I'm totally confused.
Can anyone help???