Alemox Пользователь Сообщений: 2183 |
При попытке зайти в библиотеки появляется вот такая ошибка Прикрепленные файлы
Мастерство программиста не в том, чтобы писать программы, работающие без ошибок. |
Игорь Пользователь Сообщений: 3620 |
#2 04.12.2017 16:29:28 в интернетах советуют вот что:
|
||
Андрей VG Пользователь Сообщений: 11878 Excel 2016, 365 |
Доброе время суток |
Alemox Пользователь Сообщений: 2183 |
Игорь, спасибо, попробовал такой способ. Даже перезагрузился, но проблема осталась. Мастерство программиста не в том, чтобы писать программы, работающие без ошибок. |
Андрей VG Пользователь Сообщений: 11878 Excel 2016, 365 |
#5 04.12.2017 17:04:40
Возможно. Допустим была нештатная перезагрузка — нажали reset. |
||
Alemox Пользователь Сообщений: 2183 |
Андрей VG, проверил Chkdsk ничего не обнаружил. Прикрепленные файлы
Мастерство программиста не в том, чтобы писать программы, работающие без ошибок. |
Андрей VG Пользователь Сообщений: 11878 Excel 2016, 365 |
#7 05.12.2017 08:48:07
Уже лучше. Есть возможность проверить доступ к Reference под другой учётной записью, которая ранее не использовалась на этом компьютере? Похоже слетели права доступа к реестру. |
||
Alemox Пользователь Сообщений: 2183 |
Сейчас пытаюсь восстановить права с помощью утилиты Process Monitor , но пока разобраться не могу. Пишут что Flash плеер блокирует. Но я не нашёл его по ключам в реестре. Нашёл от Adobe Acrobata одголоски, но чего с этим делать пока не понял. Мастерство программиста не в том, чтобы писать программы, работающие без ошибок. |
Alemox Пользователь Сообщений: 2183 |
Виновника нашёл. Флешплеер. Теперь надо понять что надо прописать или изменить. Мастерство программиста не в том, чтобы писать программы, работающие без ошибок. |
Alemox Пользователь Сообщений: 2183 |
Мануал написал, но весит он 300 кБ. Изменено: Alemox — 08.05.2018 21:12:12 Мастерство программиста не в том, чтобы писать программы, работающие без ошибок. |
kukhmaster Пользователь Сообщений: 20 |
Поделитесь, пожалуйста, мануалом! Такая же проблема. |
Alemox Пользователь Сообщений: 2183 |
#12 08.05.2018 21:10:46 Ссылка Мастерство программиста не в том, чтобы писать программы, работающие без ошибок. |
- Remove From My Forums
-
Question
-
Dear All,
In the VBA Editor, when try to open the reference in Tools->References, there is an error encountered with «Error accessing the system registry».
I have tried to reinstall the Office but it does not help.
By using the ProcessMonitor, I can see that Excel is trying to read the registry but all the keys are not found inside it.
Excel has been running smooth and Tools->References can be access for a long time.
How to solve this?
Answers
-
-
Marked as answer by
Monday, March 10, 2014 10:11 AM
-
Marked as answer by
-
-
Marked as answer by
George Hua
Monday, March 10, 2014 10:11 AM
-
Marked as answer by
Содержание
- Error accessing system registry vba
- Thread: [RESOLVED] Sudden «Error accessing the system registry»
- [RESOLVED] Sudden «Error accessing the system registry»
- Re: Sudden «Error accessing the system registry»
- Re: Sudden «Error accessing the system registry»
- Re: [RESOLVED] Sudden «Error accessing the system registry»
- Re: [RESOLVED] Sudden «Error accessing the system registry»
- Re: [RESOLVED] Sudden «Error accessing the system registry»
- Re: [RESOLVED] Sudden «Error accessing the system registry»
- error accessing the system registry
- error accessing the system registry
- Re: error accessing the system registry
- Re: error accessing the system registry
- Re: error accessing the system registry
- Re: error accessing the system registry
- Re: error accessing the system registry
- Re: error accessing the system registry
- Re: error accessing the system registry
- Re: error accessing the system registry
- Error accessing Project > References window?
- 13 Answers 13
Error accessing system registry vba
As the resident Excel expert at work, I have the privilege of being landed with some weird and wonderful errors which have to be fixed. Last week I developed an Excel spreadsheet for a user but when he went to test it he said he was getting an error when he tried to check the project references. Specifically when he went to Tools > References in the VBA IDE he got the message ‘Error accessing the system registry’:
This error had nothing to do with the spreadsheet I’d built for him: obviously he hadn’t tried to reach the project references menu for a little while. When you try to pull up the project references, Excel goes off and reads a bunch of keys from the registry and this error occurs when the you don’t have permission to read one or more of those keys. But how do you figure out which keys are causing the problem?
The answer is to run Process Monitor (which must be run under an admin account) because it will show you every key which Excel tries to read and whether it did so successfully. ProcMon has saved my bacon several times over the years so it’s worth a look if you haven’t come across it before.
It’s extremely easy to use: simply add a Process Name filter for EXCEL.EXE, clear the display and then, with Excel running under the user’s account, go to Tools > References and watch ProcMon burst into a flurry of activity. Once it’s calmed down you can stop capturing events and examine the output. You’re interested in any results which are ACCESS DENIED so add another filter on the Result column. In this case I have one key, HKCRTypeLib<57a0e746-3863-4d20-a811-950c84f1db9b>, which is causing the problem:
A quick Google search on that key reveals it pertains to a Flash Player update which has affected a number of people. The VBA IDE error message will go away once the admin uses the Registry Editor to grant the user read access to the access denied keys listed by Process Monitor.
Источник
Thread: [RESOLVED] Sudden «Error accessing the system registry»
Thread Tools
Display
[RESOLVED] Sudden «Error accessing the system registry»
my VB 6 (SP6) model ran smoothly until this morning when I suddenly got the message «Error accessing the system registry». When I tried to run my model on another computer, I got the same error message. So the sudden appearance of this problem seems to be related to my model (rather than the VB 6 (SP6) installation on my computers that run on Vista).
Would you have any idea how to proceed?
Thank you for your help.
Re: Sudden «Error accessing the system registry»
I have that happen under Vista now and again. I just close the IDE then open it back up again. It usually works on the 2nd try. No idea why.
Re: Sudden «Error accessing the system registry»
I did that this morning without any effect. In fact, I shut down the computer and re-tried it right afterwards, again without any success.
A few hours later I restarted the computer again, and then it worked. My problem may have had to do with the time switch last night (in Canada) from summer to regular time. At least that’s the only thing that changed to my knowledge.
Re: [RESOLVED] Sudden «Error accessing the system registry»
Hi there,
You may try the following,
Select the Microsoft Visual Basic 6.0 shortcut from the Start menu and right-click on it. Select Properties, and the property sheet for the shortcut will be displayed. Next, click on the Compatibility tab. It is recommended that you make the following changes:
1. Enable compatibility mode and select Windows XP (Service Pack 2) .
2. Check the «Disable visual themes» option .
3. Check the «Disable desktop composition» option.
4. Check the «Run this program as an administrator» option
Click on OK to save the changes. When you run Visual Basic, a User Account Control (UAC) dialog will be displayed, asking you to confirm that you wish to execute the program. This is because it’s now running with elevated privileges. You may also get a message that the color scheme has been changed to Windows Vista Basic. The Aero interface will be temporarily disabled until you close the IDE, which will resolve the performance issues with the form designer.
Re: [RESOLVED] Sudden «Error accessing the system registry»
1) Instead of installing vb6 again, try reinstalling Crystal Reports.
2) Click Start, Programs, Microsoft Visual Basic 6 and Right Click The Visual Basic 6 Shortcut Icon. A Menu Will be shown.
Now Click Run As.
A Pop up box will appear asking you which User account do you want to use to run Visual Basic.
Keep it to ‘Current User’ and remove the check from ‘Protect My Computer and data from unauthorized program activity’
This should help. Try this out.
Regards
Athar Anis
Re: [RESOLVED] Sudden «Error accessing the system registry»
I know this is an old post — but I thought it deserved a revival.
Okay new to the board, and I normally do not comment on programming sites — I just bear it all on my own lol . BUT I’ve been battling with this error on and off for the past year. For the most part, I’ve figured out what to do and have it resolved. however, it just happened again — and I couldn’t for the life of me remember what I did last time to sort it out.
I just tried the below, and from what I do remember of what I did last time — this was simplier and faster, and it worked beautifully! There’s at least hald a dozen ‘fixes’ out there for this but no one responds with what actually works or if someone else tried it. So danne, fantastic post — It works! YOU are a genious.
Now I have no valid excuse for delaying the next version of this app.
back to coding
Hi there,
You may try the following,
Select the Microsoft Visual Basic 6.0 shortcut from the Start menu and right-click on it. Select Properties, and the property sheet for the shortcut will be displayed. Next, click on the Compatibility tab. It is recommended that you make the following changes:
1. Enable compatibility mode and select Windows XP (Service Pack 2) .
2. Check the «Disable visual themes» option .
3. Check the «Disable desktop composition» option.
4. Check the «Run this program as an administrator» option
Click on OK to save the changes. When you run Visual Basic, a User Account Control (UAC) dialog will be displayed, asking you to confirm that you wish to execute the program. This is because it’s now running with elevated privileges. You may also get a message that the color scheme has been changed to Windows Vista Basic. The Aero interface will be temporarily disabled until you close the IDE, which will resolve the performance issues with the form designer.
Re: [RESOLVED] Sudden «Error accessing the system registry»
iTunes (and other apps yet to come) may also cause this problem in Win7.
This is because it runs a service which creates registry keys under the SYSTEM account.
When VB tries to enumerate the keys under HKCRTypeLib it fails and gives the error because the user running VB6.EXE (even if it set to run as administrator) does not automatically have READ rights to the key. At that point you get the «Error accessing the system registry» dialog.
To workaround/fix this:
1. Download Procmon and PsExec from sysinternals.
2. Run Procmon and add a «ProcessName» filter with VB6.EXE as the process name.
3. Then Select Project->References. And the error dialog should pop up.
4. Switch to procmon and scroll to the end of the events list — you’re looking for the last «ACCESS_DENIED» message for opening a registry key under HKCRTypeLib.
5. Thats the first key you need to change permissions on — so you’ll need to run regedit in the same account context that the keys were created in — the SYSTEM account. to do this install psexec on the windows PATH somewhere then run:
psexec -i -d -s c:windowsregedit.exe
(obviously change the path if yours is different)
this will run regedit through the SYSTEM account.
*You can verify that even the administrator account does NOT have permission to edit these keys by running regedit through a Start->Run dialog as this elevates the priv’ level to administrator.*
6. Find the key you identified in step 4 — right click it and select Permissions.
7. Find the current logged on user that you use to run VB6 with and add them with full control to the permissions list.
8. Repeat steps 3-7 because there may be more keys that exhibit this behaviour, until the Project->References dialog appears in VB6 without error.
You could also open the .vbp in notepad to see the references if you’re stuck and dont have time to do the above.
Источник
error accessing the system registry
LinkBack
Thread Tools
Rate This Thread
Display
error accessing the system registry
Hello everyone,
I have created a program for everyone at my work to use. I went to everyone’s desk to add the necessary reference libraries.
I have one computer that when i click tools>reference I get the following error: «error accessing the system registry».
Can someone please explain why this is? I was able to do it on 16 other computers.
Thanks for any help.
Re: error accessing the system registry
This looks like the type of issue that may require a repair of office to fix.
One spreadsheet to rule them all. One spreadsheet to find them. One spreadsheet to bring them all and at corporate, bind them.
A picture is worth a thousand words, but a sample spreadsheet is more likely to be worked on.
Re: error accessing the system registry
So go to programs and features >Microsoft Office and select repair?
Re: error accessing the system registry
Yes, that will initiate the repair. Good luck!
Re: error accessing the system registry
dflak,
Ok, so I tried this but still get the same error. any other ideas?
Thanks
Re: error accessing the system registry
Would the fact that every computer has different operating systems? (windows 7, XP, 8.1).
Maybe each computer has different version of excel?? Would that matter?
Thanks
Re: error accessing the system registry
Could be they dont have proper permissions to read/view/write the registry.
Can you open regedit on their computer manually?
You could try and have someone with an admin account run repair for all users on the machine.
Alternatively, you could write your code using late binding instead so you dont need to reference the libraries (unless they are 3rd party and you must reference them for some reason).
EDIT: Versions matter overall yes. Your code may need to reference different versions of Excel and/or different versions of the reference. VBA isnt one size fits all. Depending on the complexity of your code you may even need to consider 32bit machines/Office vs 64bit machines/Office.
Re: error accessing the system registry
Zer0cool,
Thanks for the reply.
Yes i can open regedit on the computers.
Re: error accessing the system registry
I don’t think that the version of Excel or even the operating system is the issue since you get the error as soon as you select Tools -> Reference. Microsoft is fond of «depreciating» things meaning that it no longer recognizes old code, so if the error happened when trying to select or use something that has been depreciated, then the version of Microsoft could be a factor, but that is not what is happening.
The next step in the troubleshooting is to de-install and re-install Office. I was hoping that a repair would rewrite the registry, but apparently it doesn’t. A complete de/re install should do this. Templates such as normal.dotm should be preserved, but I would back them up just to be safe.
If that fails then the next step would be to go to the last windows system restore point where the feature worked. However, this is probably impractical since you don’t know how long this feature has been broken.
Источник
Error accessing Project > References window?
In Visual Basic 6, when I attempt to access Project > References, it throws an error:
Error accessing system registry
- Logged in as the local computer administrator
- running Windows XP Professional and
- I can execute regedt32.exe and access all the registry keys just fine.
VB6 was installed as the local administrator.
Any idea why this happens?
I’m running crystal reports 8.5 and it supposed to already have fixed that issue but apparently I still have the issue with 8.5 installed. I have also made the attempt of reinstalling crystal reports with no luck on the issue.
13 Answers 13
Depending on the Windows OS you have (I have Windows 7 Enterprise), you might want to try giving administrator rights to the REGTLIB.EXE (located in C:Windws). Right click on the REGTLIB.EXE file. Select Properties from the pop-up menu. Then select the Compatiblity tab. On the Compatiblity tab, check/select the Run this program as Administrator checkbox. Click OK to save your changes. It might take take care of the problem for you. It worked for me. Good luck.
For me this worked:
- goto C:Program FilesMicrosoft Visual StudioVB98
- change the property of VB6.EXE by right click->Compatibility In privilege level section, check the option Run this program as Administrator
If you’re running Office 2010 (Beta) Word (apparently) writes a restricted registry key. VB throws the error when scanning the registry. The key I have is:
For Regmon — Filter for Process Name -> «vb6.exe» and Result -> ACCESS DENIED . Helps find it very quickly.
Fixed it with PSToosl (PSEXEC) to run registry editor. The command line is,
psexec -i -d -s c:windowsregedit.exe
psexec needs to be run with elevated-permissions.
Edit by Jim: I’m on a Windows 7 (x64) box. Elevated permissions require the PSTools solution. XP can get away with a little less.
You could try Process Monitor to see which registry keys are accessed.
I got this on a machine that I was using for VB6 development. I had been building a lot of COM DLLs from VB6 (without binary compatibility) and the cruft that had built up in the registry eventually got too much.
Have a look at what size the registry is and what limit you have set. I doubled the registry size and then went looking for a good registry hoover.
Here is a solution from Microsoft. It references the Crystal Reports problem, but the solution just uses regedit32 to walk the HKEY_CLASSES_ROOTTypeLib and HKEY_CLASSES_ROOTCLSID registry branches for dimmed keys and correcting the security on those keys. There are also instructions to fix the security if regedit32 is unable to access the key. Article ID: 269383
In Windows 7 go to start menu then right click «Microsoft Visual Basic 6» then select properties and click Compatibility from the dialog box that appears then tick «Run this program as an administrator».
Have you tried this? Basically, it seems that it is a crystal reports issue. Hope that helps.
Perhaps worth a try going to the «User Account Control Settings». Regards,
When I installed VB6 on Win7-64 (using instructions easily found by a search engine), it worked fine. UAC was off — i.e. set to «never notify.»
After a few weeks I turned UAC on — i.e. set it to its default. VB6 then couldn’t compile because of the «Error accessing the system registry» problem. Unfortunately, turning it off again didn’t help. Apparently the damage done by turning it on was irreversible. I can’t explain why this should be, but that’s my experience.
Giving REGTLIB.EXE administrative privileges while leaving UAC off sounded like a great idea, but that didn’t work for me either.
Finally, using Process Monitor and PsTools as described in other posts here worked. However, I had to give Full Control to large parts of my registry to Everyone. This didn’t apply just to isolated keys. It seems that the compiler needs to add keys to major nodes, so I had to open up these entire nodes.
Aside from the fact that working through these steps took hours, I’m now much more exposed than I was before I tried to increase security via UAC, However, I need VB6 and don’t see another solution short of a new computer.
Lesson: Don’t use UAC with VB6. Except if you’ve arrived here it’s too late for that.
Источник
I was working on a Form and then Access crashed. When I tried to open it, I was prompted with an error which I didn’t recognize how to fix right away. Something like
Form1 doesn’t exist , if the invalid form name is in a macro …
At the time, I couldn’t figure it out, so I hit «Compact and Repair», closed and re-opened access a few times. Then there was another message, don’t exactly remember but soemhting like «To continue, all VBA code must be deleted.» I said Ok, because I have a few back up copies. But that didn’t fix anything.
Then I figured out how to fix the original error. «Form1» was my default form to open on startup, so I changed it. So everything works, I copy the code back in, but obviously the code doesn’t work. The error message is:
Compile Error user defined type
on the DAO.QueryDef
Then I follow MS Help and check the references, and when I click on Tools -> References, I get
Error acessing the System Registry.
So, any thoughts that include not messsing with the Registry?
As the resident Excel expert at work, I have the privilege of being landed with some weird and wonderful errors which have to be fixed. Last week I developed an Excel spreadsheet for a user but when he went to test it he said he was getting an error when he tried to check the project references. Specifically when he went to Tools > References in the VBA IDE he got the message ‘Error accessing the system registry’:
This error had nothing to do with the spreadsheet I’d built for him: obviously he hadn’t tried to reach the project references menu for a little while. When you try to pull up the project references, Excel goes off and reads a bunch of keys from the registry and this error occurs when the you don’t have permission to read one or more of those keys. But how do you figure out which keys are causing the problem?
The answer is to run Process Monitor (which must be run under an admin account) because it will show you every key which Excel tries to read and whether it did so successfully. ProcMon has saved my bacon several times over the years so it’s worth a look if you haven’t come across it before.
It’s extremely easy to use: simply add a Process Name filter for EXCEL.EXE, clear the display and then, with Excel running under the user’s account, go to Tools > References and watch ProcMon burst into a flurry of activity. Once it’s calmed down you can stop capturing events and examine the output. You’re interested in any results which are ACCESS DENIED so add another filter on the Result column. In this case I have one key, HKCRTypeLib{57A0E746-3863-4D20-A811-950C84F1DB9B}, which is causing the problem:
A quick Google search on that key reveals it pertains to a Flash Player update which has affected a number of people. The VBA IDE error message will go away once the admin uses the Registry Editor to grant the user read access to the access denied keys listed by Process Monitor.
About Colin Legg
RAD Developer
Microsoft MVP — Excel
2009 — 2014
|
|