Registry blocked by UAC

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Hi, we developed an application that works fine with XP but Vista's UAC seems
to be blocking a Registry key that we generate under this path: "My
Computer\HKEY_CLASSES_ROOT\CLSID\{}"

Disabling UAC or 'Run as Aministrator' option 'helped' with the problem as a
user but as a programer i would like to know why UAC didn't prompt for
consent or if there's an appropiate place for developers to place these keys
on the registry

Thanks, Najash
 
If they need to be updated by users they should be in HKEY_CURRENT_USER.
Otherwise you can set them with the installer. Installers almost always need
administrator access and automatically generate a UAC prompt.
 
Thanks Kerry, and yes You're right, in some cases we need to create the Key
from the installer and that works just fine (UAC prompts for consent) ,the
problem comes when the Key is created out of the installer.

An example of this is when a trial version of an app. is installed and when
expired, only the key is changed for full version.

Do you know how are developers fixing this case when migrating their old
apps?
 
To update an application the updater should let Vista know it needs
elevation and Vista will throw a UAC prompt. There is no way to program
around UAC. You can turn it off but if it's on you can't get around it. As
you have no way of knowing in advance if the user has turned off UAC you
have to assume it's on and write the program for it.

http://msdn2.microsoft.com/en-us/library/aa905330.aspx
 
Thx, I really apreciate your help, reading about UAC from the links you send,
I found something about a Manifest File that might help
 
Back
Top