Registry can not be updated

  • Thread starter Thread starter José
  • Start date Start date
J

José

I have a program which updates the Registry so that a line is added to
the context menu of a jpg file. However, the update fails.

RegCreateKeyEx returns the error code 5 (ERROR_ACCESS_DENIED)

With Regedit there is no problem, so it is not a matter of privileges.
 
Hi Jos?,

Actually, it is a permissions issue. The program is likely not running with
elevated privileges, so it cannot write the key.

--
Best of Luck,

Rick Rogers, aka "Nutcase" - Microsoft MVP

Windows help - www.rickrogers.org
 
Actually, it is a permissions issue. The program is likely not running with
elevated privileges, so it cannot write the key.

I ran it under the Administrator account. To be precise: the first
account I created when the system was installed.
Besides, with Regedit it wasn't a problem to modify the registry.
 
I ran it under the Administrator account. To be precise: the first
account I created when the system was installed.

But that doesn't mean the installer runs with the same privelidges. To
make system changes, a program now has to run as Administrator and not
as a member of the Administrators group as you have been doing. Things
have changed alot. Try right clicking on the installer file and
selecting "Run as Administrator"
 
Conor is correct. In Vista an administrator runs as a user but can give
permission as an administrator to perform an action that changes the
computer. That sets up a security model where no script or program can
execute without the user's awareness. That was the problem with running as
administrator in XP. Malware could change something in the computer because
it could inherit the administrator's permissions without his knowledge.
 
Alright, so I've got a similar issue. I upgraded to Vista from XP and so
I've still got my original progams in the system. This has been a real
problem with Norton AV and getting rid of it has been a pain. The uninstall
for Norton would not work since it was not compatible with Vista. I spent a
lot of time deleting keys from the registry that were Symantec specific but
there is a set in HK Local Machine that are labled Legacy this and that and
regedit won't let me delete them even in safe mode logged in as
Administrator. What gives with that? My biggest frustration with MS
operating systems is getting past the protections to do simple stuff like
backing up critical parts of the system or deleting unwanted items. In unix,
if you're root then you are god - it doesn't seem to be that simple in either
XP or Vista.
 
Running NAV through an operating system upgrade is foolhardy at best.
NAV programs have all sorts of claws into the system, and they make a
mess on operating systems they have not been certified to run on.
Although NAV tends to make a mess everywhere.
 
Anyway, I think the Upgrade Advisor advises to uninstall NAV before
proceeding.
 
So leaving it installed even after the advisor told me it was incompatible
was a stupid thing to do. gotcha. Somehow I thought I would be able to
remove it after the upgrade. Silly me. It appearently is the offending
program that is responsible for deleting itself, not the OS. Why would I
think the OS was capable of Administering a thing like that?

Thanks for the helpful information.
 
We live and learn. :)

Kyle J. said:
So leaving it installed even after the advisor told me it was incompatible
was a stupid thing to do. gotcha. Somehow I thought I would be able to
remove it after the upgrade. Silly me. It appearently is the offending
program that is responsible for deleting itself, not the OS. Why would I
think the OS was capable of Administering a thing like that?

Thanks for the helpful information.
 
Back
Top