Pro VB 6For advanced Visual Basic coders working in version 6 (not .NET). Beginning-level questions will be redirected to other forums, including Beginning VB 6.
Welcome to the p2p.wrox.com Forums.
You are currently viewing the Pro VB 6 section of the Wrox Programmer to Programmer discussions. This is a community of tens of thousands of software programmers and website developers including Wrox book authors and readers. As a guest, you can read any forum posting. By joining today you can post your own programming questions, respond to other developersí questions, and eliminate the ads that are displayed to guests. Registration is fast, simple and absolutely free .
Hello! I have an application that works fine after registering using
Active lock and Generate key. It's installed in windows 2000 machines
and it works fine with administrator privileges. The same isn't true
when not using administrator privileges. The message is as following:
Run time error '26001'
failed to set registry value key_'-2147483646'
section:'Software\intel\c....', key:'6....'to value:"
There are sections of the windows registry that only administrative users (or PowerUsers) can modify, your application is presumably trying to change a value in one of these sections.
Change your app to use the HKEY_CURRENT_USER registry key instead of HKEY_LOCAL_MACHINE. It will mean that every user will have different settings (and may need to each install the program), however it will correct your problem.
The Windows Registry is an incredibly complicated area, so if you are going to do any serious development that uses the registry then may I recommend you invest in a good book on the subject?
I would say I have a reasonable knowledge of the Windows registry, but I am weak in the changes from NT to 2k & XP. Most of the knowledge I have comes from experience, not a formal resouce that explains it. Do you have a book that you recommend (something from a developer's perspective, and not how to change the look & feel of windows)?
I am afraid I also have gained my knowledge by tinkering and several on-line resources. I would not say that I am an expert in the Windows registry, actually far from it, however I know the basics from a coding point of view.
usually the installation process must be done as administrator, because as others have already pointed out the registration must have full access of the registry. At run time, the registry must be accessed only for read only. Interesting enough, the error code you experienced is the generic 'out of memory' (but that is only the reported error, the real meaning can be completely different).
Do you have the problem at registration or at run time? Are you using third party components?
This error could occure when you are running a windows version from windows 2000 and later. To solve this error you should have administrator rights on your network! Follow the step below:
1) Login as administrator
2) Start the program: Regedt32.exe
3) Goto HKey_Local_Machine
4) Open the Software folder and click once on the folder Nelco.
5) Click on the menu option Security and Permisions
6) Add the Full control to all users.
7) Login as normal user and Register again.