Administrative Access to HKLM
I posted a problem to the Compatibility forum about having trouble with accessing the HKLM registry, even logged in as an administrator. It turned out I was requesting KEY_ALL_ACCESS instead of KEY_READ, and it was difficult to solve because it was completely silent. With UAC turned on, there was no elevation prompt to allow administrative access. The only way to run the program was to turn off UAC or "Run as Administrator". Is this by design, or was it just overlooked?
February 21st, 2010 3:23am

that's be design. When you run asInvoker , yor program gets the standard user rights from the limited token. So writing to HKLM fails, because you have standard user rights! Change the entry requestedExecutionLevel inside the application manifest to requireAdministrator to request an UAC elevation prompt. André"A programmer is just a tool which converts caffeine into code" CLIP- Stellvertreter http://www.winvistaside.de/
Free Windows Admin Tool Kit Click here and download it now
February 21st, 2010 5:42pm

This topic is archived. No further replies will be accepted.

Other recent topics Other recent topics