Visual Studio 2015 does not start - visual-studio

We have installed Visual Studio 2015 Professional on Windows 7. It was working fine. But after we installed updates from the menu Tools-->'Extensions and Updates' today the Visual studio does not start anymore. we tried using 'run as administrator' as well. From the Start menu we right click on 'Visual Studio 2015', then 'run as administrator', the usual dialog box asking for permissions appears, we click on 'Yes', splash screen for Visual Studio appears for a second and then disappears. On the Task Manager, it does not appear as well.
Re-starting the system does not help either. .NET 4.6 is installed and Visual Studio 2012 on the same system is working fine.
UPDATE 1
The issue started after we installed the last update (from within VS2015) that had something to do with universal apps I think.
UPDATE 2
At the exact time when I start VS2015, one Windows Event log gets generated under security section as follows:
EventID 6281
Microsoft-Windows-Security-Auditing
Audit Failure
Message: Code Integrity determined that the page hashes of an image file are not valid.
The file could be improperly signed without page hashes or corrupt due to unauthorized modification.
The invalid hashes could indicate a potential disk device error.
File Name: \Device\HarddiskVolume3\Windows\System32\l3codeca.acm

I had the same problem recently after I upgraded one of the packages. I tried "everything" and the only option that worked was the /Setup switch (I was logged in as Administrator, but don't think that's required).
c:\Program Files (x86)\Microsoft Visual Studio 14.0\Common7\IDE>devenv.exe /Setup
c:\Program Files (x86)\Microsoft Visual Studio 14.0\Common7\IDE>devenv.exe
https://msdn.microsoft.com/en-us/library/ex6a2fad.aspx

Here's what worked for me.
Go to the Command Prompt and navigate to the folder with devenv.exe
In my case it was C:\Program Files (x86)\Microsoft Visual Studio 14.0\Common7\IDE
then execute
Devenv.exe /ResetSettings
https://msdn.microsoft.com/en-us/library/ms241273.aspx

I had the same problem. It was caused by Visual Studio Extensions adding paths to $PATH, which made $PATH grow too long (>2048 bytes).
This breaks VS and lots of other stuff on your machine.
Removing outdated and duplicate lines from $PATH made it short enough and VS2015 and everything worked again.

If nothing above works (like in my case) then open a registry editor, go to HKEY_CURRENT_USER\Software\Microsoft\VisualStudio and delete all 14.0 directories.
It will reset all VS settings and next launch will be like first one after installation.
Found answer here

After trying the other solutions in this thread, what finally worked for me was:
From an elevated Command Prompt, navigate to "C:\Program Files (x86)\Microsoft Visual Studio 14.0\Common7\IDE".
Execute:
devenv.exe /Log C:\temp.log
https://msdn.microsoft.com/en-us/library/ms241272.aspx
The log should contain a matching set of Begin and End entries for every extension:
<description>Begin package load ...
...
<description>End package load ...
If the last extension is missing the End package load entry, you need to uninstall that extension.
Execute:
devenv.exe /SafeMode
https://msdn.microsoft.com/en-us/library/ms241278.aspx
Go to "Tools -> Extensions and Updates" and uninstall the offending extension.
Exit VS. Start VS as normal. In case it still doesn't work, repeat the procedure.

Nothing of above helped me, What helped me was to copy devenu.exe from other computer which had VS installed and then replacing it with mine computers devenu.exe.

Run C:\Program Files (x86)\Microsoft Visual Studio 14.0\Common7\IDE\Blend.exe
Right click on some file in "Solution Explorer" such as "default.aspx" and select "Edit in Visual Studio"

For me it only shows Visual studio 2015 window without disappearing and showing IDE or any error.
Non of following solutions worked for my normal domain user but there was no issue running it with administrator.
Devenv.exe /ResetSettings
Reinstalling
Repairing
Watching event viewer for more details
Cleaning temp and cleanup and finally seeing some error
Finally I deleted my whole profile from admin via [System properties]-> [Advanced] -> [Profile] and it resolved the problem.
Just before that copy your user folder somewhere or at least your desktop and user folders and also your bookmarks and settings.

I tried several methods above and even re-installed VS but it did not work. The final solution was to really completely remove all the settings and registries of VS with the tool VisualStudioUninstaller. After uninstalling and re-installing it, it is up again.

Related

Visual Studio Update Paused - Now cannot be resumed, modified or removed

First of all, I am trying to open a support request with Microsoft about this issue, but their support reporting portal isn't working. I have resorted to Stackoverflow because I have no way of getting to Microsoft.
Yesterday, I started updating Visual Studio 2022 from Visual Studio Installer by mistake and paused it shortly after. Today, I tried to open a project but Visual Studio seemed unavailable. At that point I remembered about the paused update and re-opened the Visual Studio installer. I tried to Resume, and I got the below error. The Modify and Remove options give out the same error too. There is no Repair option.
Sorry something went wrong
The dependent package of
'Microsoft.VisualStudio.Debugger.Concord,version=17.1.33203.90,productarch=x64'
cannot be found: Microsoft.VisualStudio.DebuggerClient.Concord,
version=[17.0,18.0].
I also tried Restarting and deleting temporary files using the Disk Cleanup tool - no difference.
I have tried to force an uninstall from the Add or Remove programs but this still redirects me to the Visual Studio installer.
I have tried to research this error online but found nothing.
I did not fix the issue but at least I managed to uninstall the Visual Studio instance to be able to start from scratch again. If you do not want to go down the route of uninstalling, feel free to try the steps as suggested by #garbagecollector.
I deleted the installation folder for 2022 from ProgramFiles.
I deleted the Visual Studio installer from Add or Remove programs. (Note: This actually uninstalled a working version of Visual Studio 2019 that I had, and left the messed up version of 2022 with the same issues, so beware if you do not want to uninstall another working version of Visual Studio)
Then I ran InstallCleanup.exe via CMD (in admin mode). Refer to the "Remove All with InstallCleanup.exe" section within this article. This seems to have cleared all Visual Studio related files including the Visual Studio
installer, and I could re-download the installer for Visual Studio
2022 Community edition and start afresh.
I faced the same issue today and could solve it by removing corresponding dependencies from _package.json files from C:\ProgramData\Microsoft\VisualStudio\Packages\[PACKAGE_NAME] folders.
I am not sure whether you can repair your installation this way, I tried only with uninstall.
So in your case edit this file:
C:\ProgramData\Microsoft\VisualStudio\Packages\Microsoft.VisualStudio.Debugger.Concord,version=17.1.33203.90,productarch=x64 and remove the line marked with "-->" under "dependencies":
{
"id": "Microsoft.VisualStudio.Debugger.Concord",
...
"dependencies": {
...
--> "Microsoft.VisualStudio.DebuggerClient.Concord": "[17.0,18.0]"
}
}
In my case I had to repeat this procedure for three or four _package.json files.

Visual studio installation path grayed out

I had to reformat one of my drives (T:) and change its purpose. I had Visual studio 2015 installed on it, uninstalled it before formatting and now the drive has a different letter (can't change it, other things installed on it). I want to install visual studio 2015 again, but on the C: drive. When I run the installation, I get this:
The T: drive doesn't exist anymore, and I can't change the installation path to another drive.
I tried some solutions where I had to delete registry keys, but didn't succeed since most of the solutions were for older versions of visual studio. Is there a way to change the path?
Run installer in command line (Admin Mode) In folder keep File vs_community_ENU.exe
and put this command
vs_community_ENU.exe /uninstall /force
Then put this
vs_community_ENU /CustomInstallPath C:\VisualStudio2015
NewDrive:\VisualStudio2015
it work for me
Hope this helps
I had the same problem. I had an installed Visual Studio on a crashed harddisk.
I tried everything above, nothing worked. You should use this method as ultima ratio:
There is a VisualStudioUninstaller by Microsoft.
Download it
Extract it
Run it with Setup.ForcedUninstall.exe in an administrator command prompt
If this fails:
Start an elevated powershell:
install-package msi -provider PowerShellGet
get-msicomponentinfo '{777CBCAC-12AB-4A57-A753-4A7D23B484D3}' | get-msiproductinfo | uninstall-msiproduct -properties IGNOREDEPENDENCIES=ALL
Try again. If this fails, replace the GUID with one of the following:
Visual Studio 2015: {777CBCAC-12AB-4A57-A753-4A7D23B484D3}
Visual Studio 2013: {56E09E41-21B6-4F87-8D60-0787D028ECDD}
Visual Studio 2012: {DB786F13-64A8-45D7-8C03-0E819DF9F7B3}
Visual Studio 2010: {01696F98-947C-4CF9-8BD3-ABE70332FDED}
Sources: blogs.msdn.microsoft.com
and
landinghub.visualstudio.com
If this fails get an exorcist or/and reinstall your system.
I know you said it worked, but for some (including me) it did not. After multiple hours, however, I found a way. Here are the steps to my solution:
If you have not uninstalled VS2015 yet, do it through Control Panel.
Run the setup (ect. vs_community.exe).
If you cannot install on desired drive, keep reading here :)
Copy the path from where the VS2015 want you to install it on (e.g.: "D:\Programmer\Microsoft Visual Studio 14.0").
Open regedit(Just press windows key, type it in, and press Enter).
Warning, now you are in the windows registry, be careful or you may cause system-wide instability.
Go to HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Installer\UserData Here there should be 2 folders called something like S-1-5-18 and S-1-5-21-345634235-23423416487. Just start with the one with the smallest number.
Go into the Components folder, and here you should see many folders with numbers and letters as name. Right click on the first of these, and click Search. ("Find" for Windows 10)
Paste the path from step 4. here, and make sure that the 3 top boxes are checked (they should be by default).
Right-click the first result of the search and click export. Save it somewhere you remember, then right-click it again and delete it this time.
Run the VS2015 setup again (vs_community.exe) and check if you can change the path now. If not go back to 9. and continue.
If it worked, just install VS2015 and just remember where you put your saved reg files. If anything goes wrong, you can restore them again by running the file.
Hope this helps someone!
This worked for me:
Start procmon and run the VS installation.
In procmon, find the relevant registry by looking for:
"HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Installer\UserData\*\Components"
Make sure the key you've found was successfully opened (result should be SUCCESS)
Open regedit and find the relevant Components folder.
Search for the key you have found.
Export it for backup, and then delete it.
Hope it works for you too :-)
For me, it was the mistake of installing SQL Server Management Studio 2016 before installing Visual Studio 2015. SSMS 2016 is now based of VS 2015 Shell Core. And the new setup doesn't allow for any interaction except pressing the Install button. That way, part of VS 2015 was installed to C: drive. And hence, all options to change VS 2015 Enterprise install path failed.
I removed SMSS 2016 and, explicitly, VS 2015 Shell Core and then tried to install VS 2015 and it worked with Custom Path and Browse button.
You can use junction tool by Microsoft to create a REAL directory on other partition (e.g. D:\Program Files (x86)\Microsoft Visual Studio 14.0) and make a symbol link to it as C:\Program Files (x86)..., just like the command shows below, then windows will use C:\Program Fil.. as path and the real dirs/files are in D:\Prog...
junction.exe 'C:\Program Files (x86)\Microsoft Visual Studio 14.0' 'D:\Program Files (x86)\Microsoft Visual Studio 14.0'
Download junction tool from https://technet.microsoft.com/en-us/sysinternals/bb896768.aspx
In case someone still has this problem (I had it, since I deleted my partition, on which Visual Studio was installed before):
Open the registry, go to HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\VisualStudio\Setup
and there you will find some files. At least one of these files should contain the old path. Delete the file and the installation should work now.
In case there are other people who couldn't get it to work with the solutions already posted, here's what I did:
My problem was, that I had VS installed on partition E. The harddrive containing E crashed one day, and I couldn't uninstall VS properly anymore.
/uninstall /force wouldn't do the trick, since the setup would crash every time.
So I took my partition "D" and gave it the letter "E". Now I was able to install VS to the specified path. After that, I uninstalled it with /uninstall /force and the setup finished successfully.
After that I changed the partition "E" back to "D" and was able to install VS to "D".
I hope this helps someone with the same problem.
I know this is old, but just so you know there are command line switches that are very helpful for this sort of thing. In the command prompt, call your executable followed by /CustomInstallPath then the directory, as follows (adjust your executable pathname, of course, as necessary):
vs_community__e45cb735eddf4e4b9d95904be6e1ba26.exe /CustomInstallPath
Just a heads up, this didn't work for me the first time, so don't be afraid to try a couple times. I left my computer for the weekend (logged out), and ran the exact same command without doing anything else and it worked. Go figure...
In powershell:
Remove-Item
Registry::HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Installer\UserData\S-1-5-18\Components\CACBC777BA2175A47A35A4D7324B483D
see https://stackoverflow.com/a/33839884/3353857

How to fix visual studio error "cannot find one or more components .Please re-install the application" in windows 8.1?

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 .
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
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
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 .
%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
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:
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.
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
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.
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
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
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 ?
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.
To fix this issue
Start regedit.exe
Go to HKEY_CURRENT_USER\Software\Microsoft\SQL Server Management Studio
Delete 11.0_Config
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
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.
Go to regedit.
Renaming HKEY_CURRENT_USER\Software\Microsoft\VisualStudio fixed problem for me.
No need to reinstall just reset devenv data…
cd c:\program files\microsoft visual studio 15.0\common7\ide
devenv.exe /resetuserdata
Run VS2013/12 with administrator rights.
It will work fine.
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
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.
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
restart you laptop it will be fixed.it work for me
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

Unable to start debugging because the object invoked has disconnected from its clients

I'm running Visual Studio 2012 (version 11.0.61030.00 update 4). When debugging a local console application I get the following error when I start debugging (F5):
---------------------------
Microsoft Visual Studio
---------------------------
Error while trying to run project: Unable to start debugging.
The object invoked has disconnected from its clients.
---------------------------
OK
---------------------------
This only happens if I leave visual studio alone without debugging for a couple minutes. If I close visual studio and re-open the error goes away (until I leave it untouched for another couple of minutes). Has anyone experienced this? I can't find any threads of other people experiencing it.
This may be a possible answer for the problem.
Some from the answer:
Check which files were changed (why and how) after update from a source control engine
Review the list of extensions and plugins. Try to disable all or some of them
Close Visual Studio and kill all the development processes: devenv, mspdbsrv, vcpkgsrv, msbuild, msvsmon, vshub, vstest etc
Remove .suo, .ncb, .VC.db, .VC.VC.opendb files of the solution as well as .vs directory, which sometimes cause problems
Remove project setting files, sort of YourProjectName.vcproj.DOMAINNAME.LOGINNAME.user or YourProjectName.csproj.user. The setting file name depends on a project kind you use
Run "C:\Program Files\Microsoft Visual Studio 10.0\Common7\IDE\devenv.exe" /setup or "C:\Program Files (x86)\Microsoft Visual Studio 10.0\Common7\IDE\devenv.exe" /setup for x64 environment
Just Close the VIsual Studio and start again the project.Its work Perfectly for me.
Thanks
While restarting Visual Studio does provide a workaround, it doesn't solve the actual problem. In my case, I was working with a C# solution in VS2017 and the following resolved the issue:
Close Visual Studio
Delete the .vs folder that was created in the Solution's directory
Re-open the Solution
I corrupted my App.config file with NLog settings without section Handler in the top of the document. Gist is check out your config file settings either corrupted in format or not properly handled any section. once I remove corrupted config section, it did not raise the error again (VS 2017)
Hope it helps!
In my case I have just reinstalled Windows 10 and so the Visual Studio 2022..
My project was targeting .net 5 SDK, but I only had .net 6 SDK installed. The solution was to install earlier version of the SDK.

Visual Studio 2012 syntax coloring for C# types [duplicate]

Somehow part of my syntax highlighting for C# code has disappeared in the VS 2012 IDE. Uninstalling, rebooting, and reinstalling does nothing, nor does resetting the colors in the options dialog.
Here are some examples of items which all appear in default (black) that normally have color which don't:
Attributes
System classes
My own classes
And here are some keywords that still have color:
using
public
void
var
for
Has anyone else experienced this and managed to fix it?
Here is a simple solution. Go to the directory where devenv is (for 2012 RC), and type devenv.exe /setup. It will fix your problem.
devenv.exe is usually in something like C:\Program Files (x86)\Microsoft Visual Studio 11.0\Common7\IDE.
Edit: It has been suggested that you do this from the Visual Studio command prompt (Start>Microsoft Visual Studio>Tools>Visual Studio Command Prompt), and/or make sure your command prompt has administrator permissions.
Note for others: This has a very good chance of working for many other versions of Visual Studio, including 2008, 2010, 11 beta, ...
My problem was limited to having the "DateTime" type not showing up in light blue like other class names. I fixed it by simply switching back-and-forth between VS Themes. Discovered by accident. Much quicker than reset settings or repair install...
VS menu Tools -> Change Color Theme
This is what worked for me:
1 - delete all in C:\Users\userNAme\AppData\Roaming\Microsoft\VisualStudio\11.0
2 - open vs console as administrator, and run:
devenv.exe /setup
devenv.exe /ResetSettings
This will reset all your environment settings.
If none of the above work for you, delete all GUID-named folders under this registry key (make sure your Visual Studio instance is closed):
If you're using Visual Studio 2012:
HKEY_CURRENT_USER\Software\Microsoft\VisualStudio\11.0\FontAndColors
If you're using Visual Studio 2013:
HKEY_CURRENT_USER\Software\Microsoft\VisualStudio\12.0\FontAndColors
If you're using Visual Studio 2015:
HKEY_CURRENT_USER\Software\Microsoft\VisualStudio\14.0\FontAndColors
Restart Visual Studio, and you should see a few various "User Types" to configure. You can then import your Fonts and Colors that you backed-up, and everything will be good to go. This may also work for previous and future versions of VS, but I have not tested.
Disclaimer: Make sure you export/backup your current Fonts and Colors settings before making these registry adjustments. I cannot be held responsible for you losing your configs :)
If you still have this issue try ResetSettings (worked for me)
NOTE: this will reset the Visual Studio 2012 settings :)
1) close vs.
2)open cmd (as administrator).
3) go to devnev.exe folder (something like "C:\Program Files (x86)\Microsoft Visual Studio 11.0\Common7\IDE" ).
4) type "devnev.exe /ResetSettings"
5) open vs and look at the beautiful colors
Found the source of the problem:
If you have the "Productivity Power Tools 2012" installed,
you should go to Tools -> Options -> Productivity Power Tools
and turn off the "Colorized Parameter Help" option.
This fixed the syntax highlight problem.
If anybody runs in to the same problem for Visual Studio 2013 as I did, the only solution that worked for me was to first close VS2013 and then delete the following registry key:
HKEY_CURRENT_USER\Software\Microsoft\VisualStudio\12.0\FontAndColors
After reopening VS2013, my syntax highlighting for types was restored.
Prior to deleting the registry key, I noticed that all of the "User Types..." settings in the Fonts and Colors section of Tools > Options were missing. Deleting the registry key restored them. They attained their default values which gave me the syntax highlighting colors I was looking for.
This was the only solution that worked for me. Switching themes, resetting my personalized settings to defaults, running devenv.exe with various command line switches to setup/reset Visual Studio did not work.
I also created the following bug report with Microsoft on their Connect site:
http://connect.microsoft.com/VisualStudio/feedback/details/810985/incorrect-syntax-highlighting-for-c-types.
For me "Productivity Power Tools 2012" was the cause. Nothing suggested here helped. After removing the Power Tools the colors came back.
I did all the things listed here and still nothing (VS2013 Update 3). I tried /setup, /resetsettings, deleting the stuff in AppData, deleting the registry keys. Still, User Types wouldn't be highlighted even in the default color scheme.
What helped in the end was opening the Fonts and Colors dialog, selecting Identifier, and making it Bold. Then removing the Bold. Instant fixage!
I had the same issue....just uninstalling and re-installing alone did not correct the problem. After I un-installed, deleted all remnants of VS 2012 in program files, removed all related registry keys, and deleted the VS 2012 folder from My Documents, then re-installed, user types showed up in the display items in fonts and colors and everything went back to normal. My guess is that it was an issue with one or more of the registry keys but I can't be sure of that.
exit devenv
go to below path
hkey_current_user\software\microsoft\visualstudio!
remove 9.0 , 10.0 , 10.0_config (i mean to say all other folders except 11.0 and 11.0_config)
Now start devenv and see the magical colors get back normal
1 - delete all in C:\Users\userNAme\AppData\Roaming\Microsoft\VisualStudio\11.0
2 - open vs console as administrator, and run:
devenv.exe /setup
devenv.exe /ResetSettings1 - delete all in C:\Users\userNAme\AppData\Roaming\Microsoft\VisualStudio\11.0
2 - open vs console as administrator, and run:
devenv.exe /setup
devenv.exe /ResetSettings
This is what helped me...
delete all in C:\Users\userNAme\AppData\Roaming\Microsoft\VisualStudio\11.0
open vs console as administrator, and run:
devenv.exe /setup
devenv.exe /ResetSettings
This solution worked for me. Thanks alot Gaz Winter
If you've installed the preview of Roslyn, unintstall it. This worked for me.
After trying several of the solutions listed here, I eventually found that my issue was caused by a very large (488000+ characters) string variable. Highlighting was working up to that line, but not after it. Once I reduced the length of the string, highlighting in the rest of the file resumed working normally.
I already had VS 2012 Pro installed on my machine. I then installed VS 2013 Pro and started facing this color issue. I then deleted the HKEY_CURRENT_USER\Software\Microsoft\VisualStudio\12.0\FontAndColors key and opened VS 2013. This approach solved my issue and the colors were back.
If the windows desktop is configured with a high contrast theme the syntax coloring seems to disappear completely from Visual Studio. If this is the case, select a normal windows theme and set a solid background color (if you don't want a background pictures) to restore syntax coloring in VS.
Problem : Class name and Syntax showing in black color
Solutation:
Step 1: Remove Key :
HKEY_CURRENT_USER\Software\Microsoft\VisualStudio\12.0\FontAndColors
Step 2: Remove folder :
C:\Users\UserName\AppData\Roaming\Microsoft\VisualStudio\12.0
Step 3: Open command prompt (admin mode) and run below command line :
C:\Program Files (x86)\Microsoft Visual Studio 12.0\Common7\IDE>devenv.exe /setup
C:\Program Files (x86)\Microsoft Visual Studio 12.0\Common7\IDE>devenv.exe /ResetSettings
It work for download this "Productivity Power Tools 2012" and install, after install this tool get this steps go to Tools -> Options -> Productivity Power Tools and turn off the "Colorized Parameter Help" option.
This fixed the keyword as syntax ActionResult is not set for default black color and highlight problem resolved.

Resources