April 3rd, 2014, 08:46 PM
CRegKey Create() not working
Hi. I'm having issues with the following code. It's used to fix weird colors with certain games on Vista / 7. It seems to work for almost everyone. But, I found an exception today.
I have verified that UAC is disabled. The program and user have full privileges to those keys. Create() returns ERROR_SUCCESS. But, the key never gets created. Interestingly, there is another spot that the key has to be created in on 64-bit systems:
x = rk.Create( HKEY_LOCAL_MACHINE, "Software\\Microsoft\\DirectDraw\\Compatibility\\Duke Nukem 3D");
This works fine. Why would the second one work, but not the first?
x = rk.Create( HKEY_LOCAL_MACHINE, "Software\\Wow6432Node\\Microsoft\\DirectDraw\\Compatibility\\Duke Nukem 3D");
Also, if I do these from a reg file, they both work...
Click Here to Expand Forum to Full Width
This a Codeguru.com survey!