23

As Alex suggests 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 .

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 .

How can I create shortcut or which file should I execute to open IDE ?

One answer would be search in search charm ,it's not there . I tried all methods that i could .

Following folders are there in windows 8.1 program files

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 .

Community
  • 1
  • 1
user3919801
  • 519
  • 1
  • 4
  • 14

20 Answers20

35

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
bummi
  • 27,123
  • 14
  • 62
  • 101
Arjan van Dam
  • 359
  • 3
  • 3
  • 7
    This solution worked for Visual Studio 2015 too, I just needed to change the first line to: C:\Program Files (x86)\Microsoft Visual Studio 14.0\Common7\IDE. Thanks! – Aki Jan 08 '16 at 09:20
  • 3
    When I tried, the command-line gave me the same error: C:\Program Files (x86)\Microsoft Visual Studio 14.0\Common7\IDE>devenv /resetuserdata Cannot find one or more components. Please reinstall the application. – Shaun Wilson Jan 11 '16 at 16:39
  • 2
    When I tried (after applying Update 2) devenv /resetuserdata responds with "Unknown Error." – Chris Schaller May 06 '16 at 02:12
  • 1
    Worked like a charm! @ChrisSchaller I did get the Unknown Error, and I ignored it. I later got a message about an extension not loaded. Works fine now. – SarjanWebDev Jun 23 '16 at 23:02
  • VS2017 devenv executable is located at `C:\Program Files (x86)\Microsoft Visual Studio\2017\Enterprise\Common7\IDE\` – T_D Nov 27 '18 at 08:33
  • Just happened to me on Visual Studio 2015. Yup. Worked like a charm using C:\Program Files (x86)\Microsoft Visual Studio 14.0\Common7\IDE and then running devenv /resetuserdata – Michael Jun 09 '20 at 14:06
7

I had solved the same issue on VS2012 as following steps:

• Use regedit.exe

• Go to HKEY_CURRENT_USER\Software\Microsoft\VisualStudio

• Delete "11.0_Config" & "11.0 node" notice: 11.0 as your VS version

• Restart VS2012 VS env will be constructed initially.

Hope this help. BR

littlefaint
  • 71
  • 1
  • 2
  • Not exactly, for me it's delete the whole VisualStudio folder in regedit, and restart VS in administrator, it will init the settings. After that, VS can be run on non-administrator – cdytoby Jul 26 '16 at 23:02
  • Note that you'll lose some settings this way (e.g. window layout, most recent solutions, etc.). – Cameron Jul 27 '16 at 18:38
4

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 .

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 .

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 .

user3919801
  • 519
  • 1
  • 4
  • 14
  • Did that and added my restricted account as owner with full permissions but it still complains about the same "Cannot find one of its components" – Lord of Scripts May 06 '16 at 17:38
  • 3
    It's ridiculous when people mark themselves as correct. Especially when it's some generic non-specific solution. I can tell you that I have full permissions on this folder by default and still have the missing components issue. – Frank May 14 '16 at 01:04
3

%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.

Oh, and if you're on a 32-bit install of Windows, then use:

%programfiles%\Microsoft Visual Studio 12.0\Common7\IDE\devenv.exe
Ahmed Ashour
  • 5,179
  • 10
  • 35
  • 56
Alex Hardwicke
  • 529
  • 6
  • 16
  • devenv.exe file is not there . – user3919801 Oct 03 '14 at 09:36
  • In neither Program Files nor Program Files (x86)? In that case, you've either installed VS to a custom folder (search for devenv.exe, that's Visual Studio), or it didn't install properly (in which case, re-installing it should fix it). – Alex Hardwicke Oct 03 '14 at 09:52
  • i search for it only one file is there and getting error "cannot find one or more components .Please reinstall the application" . – user3919801 Oct 03 '14 at 10:16
  • 1
    Then sadly, I suggest doing what the file says: reinstalling Visual Studio. It looks like the install messed up somehow. Sorry I can't be of more help! – Alex Hardwicke Oct 03 '14 at 10:23
  • If its Windows 8.1 You can search Visual Studio as "vs Express for Windows Phone" and once you find, On right click you will see options like: Pin to start and also "Open file Location".. You can create shortcut after you get to that location by copy-paste.. – Pratik Goyal Oct 03 '14 at 10:48
  • @AlexHardwicke getting same error again and again . How to fix this . – user3919801 Oct 04 '14 at 15:42
  • @PratikGoyal vs Express means Express edition correct ? If it's correct then it won't work since i installed Ultimate edition . – user3919801 Oct 07 '14 at 08:13
  • Then you can search for that but if you even than can not find it that you should re-install it.. – Pratik Goyal Oct 07 '14 at 09:21
2

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.

In general, thats how I figured out what the problem is:

  1. Download and extract Windows Process Monitor https://technet.microsoft.com/en-us/library/bb896645.aspx

  2. Run Process Monitor, include Process devenv.exe to the filters, exlcude Result SUCCESS, and click ok.

  3. 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)

  4. 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.

Josh Crozier
  • 233,099
  • 56
  • 391
  • 304
Metaller
  • 21
  • 1
2

For Visual Studio 2015 I had to delete these keys in regedit.exe:

HKEY_CURRENT_USER\Software\Microsoft\VisualStudio\14.0
HKEY_CURRENT_USER\Software\Microsoft\VisualStudio\14.0_Config
Tonatio
  • 4,026
  • 35
  • 24
1

One possible user friendly workaround is to use the take ownership method from How to Geek and 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.

mechanicious
  • 1,576
  • 2
  • 15
  • 32
1

Was facing the same issue with VSExpress 2015 (win 10). Fixed the problem by removing the registry key in

[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

Alx
  • 11
  • 1
0

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

T3 H40
  • 2,326
  • 8
  • 32
  • 43
  • Since this is not a tested solution, please change it to a comment. If you have more evidence that this *is* the problem, please present it. Otherwise, it's a suggestion that *may* solve the user's problem. – Prune Oct 13 '15 at 17:38
  • Yes, I have changed the name of folder. So how do I let Windows know that I have changed it so it can run? – David Kasabji Feb 18 '16 at 09:07
0

I'm on windows 7 32bits SP1. this worked for me :

run cmd.exe with elevated privileges (run as administrator). then execute :

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

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 ?

reuns
  • 854
  • 10
  • 14
0

I had the same problem, and it turned out to be that my password on my local admin account expired. I use a regular account to login to Windows, but run Visual Studio as Administrator. Upon opening Visual Studio as Administrator, it prompts me for my local admin credentials, and because my password had expired, it gives me this error message.

Solution: Log out of Windows. Switch users, and login as the local admin. Windows will tell you that your password has expired. Change the password, and log out. Log back in as your normal user account, and try running Visual Studio again, this time entering the new admin password.

Pavel
  • 704
  • 11
  • 25
0

To fix this issue

  1. Start regedit.exe
  2. Go to HKEY_CURRENT_USER\Software\Microsoft\SQL Server Management Studio
  3. Delete 11.0_Config
  4. Restart ssms.exe

https://social.msdn.microsoft.com/Forums/sqlserver/en-US/b6d2b85d-c6e1-464a-85e0-e0625e7fb305/microsoft-visual-studio-shell-isolated-cannot-find-one-or-more-components?forum=sqlexpress

swiftBoy
  • 35,607
  • 26
  • 136
  • 135
  • I had the error opening SSMS and this resolved it for me, I tried other solutions (devenv.exe /resetuserdata), so this solution is very specific to SSMS. I was a bit apprehensive deleting entire key but it worked out fine. Make sure you delete the correct version config, in my case SQL Server v. 17 (it was 14.0_Config). – Imran Shaik Oct 03 '17 at 14:25
0

This is probably specific to people working with Isolated Shell applications based on VS 2015, but I found that two registry values were sometimes getting set with incorrect values, leading to this error on startup. Simply delete them from the registry and start again:

HKCU\Software\Company\TheApp\1.0_Config\Initialization\PkgDefSearchPath
HKCU\Software\Company\TheApp\1.0_Config\Initialization\RelativeRootFolderPath

For Visual Studio 2015, replace Company\TheApp\1.0_Config with Microsoft\VisualStudio\14.0_Config.

Cameron
  • 96,106
  • 25
  • 196
  • 225
0

Go to regedit. Renaming HKEY_CURRENT_USER\Software\Microsoft\VisualStudio fixed problem for me.

0

No need to reinstall just reset devenv data…

  1. cd c:\program files\microsoft visual studio 15.0\common7\ide
    devenv.exe /resetuserdata
    
  2. Run VS2013/12 with administrator rights.

It will work fine.

Nathan Tuggy
  • 2,237
  • 27
  • 30
  • 38
0

Visual Studio Enterprise 2017 Version 15.8.6

Run cmd as administrator, then:

cd C:\Program Files (x86)\Microsoft Visual Studio\2017\Enterprise\Common7\IDE

devenv /resetuserdata
Stephen Rauch
  • 47,830
  • 31
  • 106
  • 135
0

For users experiencing this issue who has tried all the above answers, this is what worked for me for Visual Studio 2015:

  • After uninstalling/reinstalling Visual Studio 2015, if you're still experencing the "Cannot find one or more components" error, open up Add or Remove Programs from the Windows search bar.

  • Uninstall any redistributables from 2015 and 2017 if applicable.

  • If you happen to have the offline install folder for Visual Studio 2015 - navigate to the "packages/vcRedistD14" folder and install both the 32 bit and 64 bit redistributable packages. Otherwise, download them from the MS website.

  • Attempt to open Visual Studio 2015, it should be working normally now.

I haven't attempted to reinstall the 2017 redist packages, but for the purposes of getting 2015 working again, this is what worked for me. Another option if you already have them installed, is to simply Repair the redist packages.

Chris
  • 2,254
  • 8
  • 22
-1

Running cd C:\Program Files (x86)\Microsoft Visual Studio 12.0\Common7\IDE devenv /resetuserdata using the command prompt works fine. The only thing which everyone has missed is that you will have to reboot your PC after running the above command. I was having same error after running the command several times but was fixed after I rebooted my machine. And of course for VS 2015 replace Microsoft Visual Studio 12.0 with Microsoft Visual Studio 14.0

Khalid Choudhry
  • 477
  • 4
  • 4
-1

restart you laptop it will be fixed.it work for me

-3

well, it seems simple but it work like magic

input visual studio in your windows search bar then right click on the visual studio app and choose run as administrator

all things been equal, it should run without an itch