如何修复 Windows 8.1 中的 Visual Studio 错误“找不到一个或多个组件。请重新安装应用程序”?
声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow
原文地址: http://stackoverflow.com/questions/26176476/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me):
StackOverFlow
How to fix visual studio error "cannot find one or more components .Please re-install the application" in windows 8.1?
提问by user3919801
As Alexsuggests find devenv.exe
and run it . when search for devenv.exe
then I found it's there . When I run this file getting error "cannot find one or more components .Please reinstall the application
" .I re-installed visual studio thrice still getting same error . How to fix this error .
It's visual studio ultimate with update 3 . I don't have ISO file , file automatically downloaded by installer.It's got installed smoothly i.e. without giving any error .
正如亚历克斯所建议的那样,找到devenv.exe
并运行它。当搜索devenv.exe
然后我发现它在那里。当我运行此文件时出现错误“ cannot find one or more components .Please reinstall the application
”。我重新安装了三次 Visual Studio 仍然出现相同的错误。如何修复此错误。它是带有更新 3 的 Visual Studio Ultimate。我没有 ISO 文件,安装程序自动下载的文件。安装顺利,即没有出现任何错误。
Edit:
Initial question was How to create shortcut on windows 8.1 for visual studio ?
Contents :
Today I installed visual studio 2013 with windows phone SDK and Multi-device Hybrid apps on windows 8.1 .Unfortunately I am unable to find any shortcuts related to any one of the applications which are installed today .
编辑:
最初的问题是如何在 windows 8.1 上为 Visual Studio 创建快捷方式?
内容:
今天我在 Windows 8.1 上安装了带有 Windows Phone SDK 和多设备混合应用程序的 Visual Studio 2013。不幸的是,我找不到与今天安装的任何应用程序相关的任何快捷方式。
How can I create shortcut or which file should I execute to open IDE ?
如何创建快捷方式或应该执行哪个文件来打开 IDE?
One answer would be search in search charm
,it's not there . I tried all methods that i could .
一个答案是search in search charm
,它不存在。我尝试了所有可能的方法。
Following folders are there in windows 8.1 program files
Windows 8.1 程序文件中有以下文件夹
C:\Program Files\iTunes
C:\Program Files\iPod
C:\Program Files\Windows Identity Foundation
C:\Program Files\Hyper-V
C:\Program Files\Common Files
C:\Program Files\IIS Express
C:\Program Files\Microsoft Identity Extensions
C:\Program Files\SharePoint Client Components
C:\Program Files\Microsoft SQL Server
C:\Program Files\Application Verifier
C:\Program Files\MSBuild
C:\Program Files\IIS
C:\Program Files\Microsoft Visual Studio 12.0
Many folders are there related to these apps in programfilesx86 .
C:\Program Files\iTunes
C:\Program Files\iPod
C:\Program Files\Windows Identity Foundation
C:\Program Files\Hyper-V
C:\Program Files\Common Files
C:\Program Files\IIS Express
C: \Program Files\Microsoft Identity Extensions
C:\Program Files\SharePoint Client Components
C:\Program Files\Microsoft SQL Server
C:\Program Files\Application Verifier
C:\Program Files\MSBuild
C:\Program Files\IIS
C:\ Program Files\Microsoft Visual Studio 12.0
programfilesx86 中有许多与这些应用程序相关的文件夹。
采纳答案by user3919801
Problem is with security setting . After 2-3 hours of Googling i found many solution but none of them work then i tried these solutions .
问题在于安全设置。在谷歌搜索 2-3 小时后,我找到了很多解决方案,但没有一个有效,然后我尝试了这些解决方案。
There is one folder in your machine: "C:\ProgramData".
Don't worry if you don't see this folder, unhide all the folders, you will find it there.
I did not had the rights on "C:\ProgramData\Microsoft\VisualStudio" .
See if you have full rights on the same.
If your are not able to open this folder, This means that you do not have rights on this.
to give rights follow the steps below :
1) Right click on the folder "VisualStudio."
2) Go to Properties->Security. See if your PC name is there in the user names list,
if not , then add it.
3) Go to Advanced -> Owner -> Edit -> Other users or groups. add your PC name,
i.e add yourself as the owner of the folder and give full rights.
Which is found here Application-data-folder-error. I was unable to change security of ProgramData files then i tried this solution .
可以在这里找到Application-data-folder-error。我无法更改 ProgramData 文件的安全性,然后我尝试了这个解决方案。
1. On the root folder, right click, select properties, select security tab.
2. Click Advanced
3. The window that pops up should show the current owner. Click "Change."
The "Select User or Group" pop up box appears.
4. In the text box, type in your current user name (you should be an admin), and hit the
"Check Names" button. Your name will be replaced with the "official" system
name (i.e.,preceded by computer name and back slash).
5. Click OK
6. The box disappears, sending you back to the Advanced Security Settings window.
7. A new tick box appears below owner, with the text "Replace owner on subcontainers and
objects" Select this tick box.
8. I also selected the tick box "Replace all child object permission entries
with inheritable permission entries from this object", but I think I had to run this twice
- once with this box ticked and once without.
9. Make sure that "everyone" appears on the Permission entries window, if not,
click add. The same box that appears in step 4 shows up again.
Type everyone, click "Check Names" and then "OK"
10. Hit apply
which is found here Permission error.
这是在这里找到权限错误。
Finally it works cheers :) Hope it will help to some other .
最后它工作欢呼:) 希望它会帮助其他人。
回答by Arjan van Dam
Same problem for me. My solution:
Open command prompt as administrator
对我来说同样的问题。我的解决方案:
以管理员身份打开命令提示符
cd C:\Program Files (x86)\Microsoft Visual Studio 12.0\Common7\IDE
devenv /resetuserdata
回答by littlefaint
I had solved the same issue on VS2012 as following steps:
我已经按照以下步骤在 VS2012 上解决了同样的问题:
? Use regedit.exe
? 使用 regedit.exe
? Go to HKEY_CURRENT_USER\Software\Microsoft\VisualStudio
? 转到 HKEY_CURRENT_USER\Software\Microsoft\VisualStudio
? Delete "11.0_Config" & "11.0 node" notice: 11.0 as your VS version
? 删除“11.0_Config”和“11.0节点”通知:11.0作为你的VS版本
? Restart VS2012 VS env will be constructed initially.
? 重启 VS2012 VS env 将初步构建。
Hope this help. BR
希望这有帮助。BR
回答by Alex Hardwicke
%programfiles(x86)%\Microsoft Visual Studio 12.0\Common7\IDE\devenv.exe
should work. The VS version number (12.0) depends on your installed Visual Studio, of course.
%programfiles(x86)%\Microsoft Visual Studio 12.0\Common7\IDE\devenv.exe
应该管用。当然,VS 版本号 (12.0) 取决于您安装的 Visual Studio。
Oh, and if you're on a 32-bit install of Windows, then use:
哦,如果您安装的是 32 位 Windows,请使用:
%programfiles%\Microsoft Visual Studio 12.0\Common7\IDE\devenv.exe
回答by Metaller
I have come across this problem while installing VS 2015 community. For me the problem was that I had ThreatFire running, which prevented VS from loading some dll. Deinstalling ThreatFire was the only solution. You cannot just stop it, as the actual service will still continue to run.
我在安装 VS 2015 社区时遇到了这个问题。对我来说,问题是我运行了 ThreatFire,这阻止了 VS 加载一些 dll。卸载 ThreatFire 是唯一的解决方案。您不能只是停止它,因为实际服务仍将继续运行。
In general, thats how I figured out what the problem is:
一般来说,这就是我想出问题所在的方式:
Download and extract Windows Process Monitor https://technet.microsoft.com/en-us/library/bb896645.aspx
Run Process Monitor, include Process devenv.exe to the filters, exlcude Result SUCCESS, and click ok.
Process Monitor will display a huge list of file and registry accesses. Go through the list and look for events with Result ACCESS DENIED or FILE/PATH NOT FOUND. (You can filter the list even more using right click context menu)
That should give you usefull hints about what is really going wrong as the VS error message really is no help at all. You can also view the stack trace that generated the event. Thats how I found out about ThreatFire blocking dll loading.
下载并解压 Windows Process Monitor https://technet.microsoft.com/en-us/library/bb896645.aspx
运行 Process Monitor,将 Process devenv.exe 包含到过滤器中,排除 Result SUCCESS,然后单击 ok。
Process Monitor 将显示一个巨大的文件和注册表访问列表。浏览列表并查找 Result ACCESS DENIED 或 FILE/PATH NOT FOUND 的事件。(您可以使用右键单击上下文菜单进一步过滤列表)
这应该为您提供有关真正出错的有用提示,因为 VS 错误消息实际上根本没有帮助。您还可以查看生成事件的堆栈跟踪。这就是我发现 ThreatFire 阻止 dll 加载的方式。
回答by Tonatio
For Visual Studio 2015 I had to delete these keys in regedit.exe
:
对于 Visual Studio 2015,我必须删除这些键regedit.exe
:
HKEY_CURRENT_USER\Software\Microsoft\VisualStudio.0
HKEY_CURRENT_USER\Software\Microsoft\VisualStudio.0_Config
回答by Alx
Was facing the same issue with VSExpress 2015 (win 10). Fixed the problem by removing the registry key in
VSExpress 2015 (win 10) 也面临同样的问题。通过删除注册表项解决了该问题
[HKEY_CURRENT_USER\Software\Microsoft\WindowsNT\CurrentVersion\ AppCompatFlags\Layers]
[HKEY_CURRENT_USER\Software\Microsoft\WindowsNT\CurrentVersion\ AppCompatFlags\Layers]
Refer the link for more details http://maditguy72.blogspot.ru/2013/06/cannot-find-one-or-more-components.html
有关更多详细信息,请参阅链接 http://maditguy72.blogspot.ru/2013/06/cannot-find-one-or-more-components.html
回答by mechanicious
One possible user friendly workaround is to use the take ownership
method from How to Geekand use it on %USERPROFILE%\AppData
and on C:\ProgramData
where C
is the disk partition holding your OS. However you'll need to make hidden folders visible first. Then navigate to your VS installation folder and run devenv /resetuserdata
.
一个可能的用户友好的解决方法是使用的take ownership
方法,从如何野人和使用它%USERPROFILE%\AppData
,并在C:\ProgramData
那里C
是磁盘分区牵着你的操作系统。但是,您首先需要使隐藏文件夹可见。然后导航到您的 VS 安装文件夹并运行devenv /resetuserdata
.
回答by MinhTai Le
I had the same problem, and I have fixed it. You should check the name of the folder in which you installed visual studio. If its name has been changed, windows can not find the components to execute. For this reason, windows will show an error message box to you
我有同样的问题,我已经解决了。您应该检查安装 Visual Studio 的文件夹的名称。如果其名称已更改,Windows 将无法找到要执行的组件。为此,Windows 将向您显示一个错误消息框
回答by reuns
I'm on windows 7 32bits SP1. this worked for me :
我在 Windows 7 32 位 SP1 上。这对我有用:
run cmd.exe
with elevated privileges (run as administrator). then execute :
运行cmd.exe
以高特权(如运行管理员)。然后执行:
cd c:\program files\microsoft visual studio 15.0\common7\ide
devenv.exe /resetuserdata
devenv.exe
before that I tried to give full rights (for my user account and also the weird Account-unknown(S1-5-21-13113034....)) to these folders: c:\program files\microsoft visual studio 14.0
and c:\users\_myname_\appdata\local\microsoft
在此之前,我尝试授予这些文件夹的全部权限(对于我的用户帐户以及奇怪的Account-unknown(S1-5-21-13113034....)): c:\program files\microsoft visual studio 14.0
和c:\users\_myname_\appdata\local\microsoft
note that when installing visual studio, I changed the default folder name to c:\program files\microsoft visual studio 2015
so maybe it is related to the bug seen later ?
请注意,在安装visual studio时,我将默认文件夹名称更改为 c:\program files\microsoft visual studio 2015
因此可能与稍后看到的错误有关?