问题
in VS 2017 when I connect to a Team Project in TFS 2013, I get an error:
Access to the Registry Key 'HKEY_CURRENT_USER\Software\Microsoft\VisualStudio\15.0\TeamFoundation\Instances\xxx' is denied.
The problem exists only in one of our two Team Project Collections after I reinstalled my workstation (Windows 7). My working account has no Admin privileges.
回答1:
First you could use another user account to connect the same team project to narrow down the issue.
If you got the same result. This should be a client side issue.Try to remove the TFS server in VS and clear TFS and VS cache. Re-add the server and connect to the team project again. You could also try to run VS with admin mode.
If another account could connect successfully. Suggest you to ask your TFS Admin to double check related permission for your account to connect the project in that specific team project collection.
回答2:
In some cases the error message is because the Registry Key is missing!!
This particular error refers to the Registry not VS2017's own special registry hive.
Open the registry in Admin mode
Start > type Regedt32 > right click Run As Admin.
If the Instances Key doesn't exist, right click on TeamFoundation > Add Key > Instances.
回答3:
There have been a number of on-going bugs for Visual Studio 2017 1 running on Windows 7. The workaround which worked for me was.
- Shutdown Visual Studio.
- Drop your user into the Local Administrators Group (Temporarily)
- Carry out the action which is throwing Unknown Error/Can't access Registry Key
- Shutdown Visual Studio and remove user from admin group.
- Carrying out the action now longer throws the error has
Access Denied error creating registry keys on Windows 7
回答4:
I have solved this problem with a tip from Jeremy Thompson.
- Open regedit (under your not admin account)
- Add the missing key
Instances
underteamFoundation
After that you can access TFS but I get another error about WorkItemtracking
. There for you must add this Add
key. For example:
image
Now you don't need to start VS2017 under admin user.
来源:https://stackoverflow.com/questions/43867525/access-to-registry-denied-when-connecting-to-team-project