Visual Studio 2015 - Can't see code to existing project

18,553

Solution 1

Fixed with the following for me.

Change 'Color Theme' to something other that what you have. Tools -> Options -> Environment -> Color theme:

Select OK then exit Visual Studio.

Open project and should see your source.

Solution 2

Please clear Visual Studio Cache, then open the Visual Studio again. You can find cache folder on follwing path

C:\Users\<your_username>\AppData\Local\Microsoft\VisualStudio\<VS_version>\ComponentModelCache

Note : Close Visual Studio, and stop all Visual Studio processes.

Share:
18,553
Admin
Author by

Admin

Updated on June 26, 2022

Comments

  • Admin
    Admin almost 2 years

    When I open a C++ project created recently on Visual Studio 2015 I am able to debug it and have it run, but the code window is blank. I've clicked all around and can not find anything to show me the code so I can continue to work on it.

    I have tried:

    • F7: View Code does not work.
    • Opening from the Solution Explorer window does not do anything.
    • Searching Google, Stack Exchange, and YouTube tutorials for my identical problem.

    I suspect it is a very straightforward misunderstanding of the interface on my part, but wanted to get involved on Stack Exchange to figure it out.

    [Screenshot of VS2015 at point of problem.

  • Joseph Ferris
    Joseph Ferris over 6 years
    I ran into the exact same issue as the OP and this solution worked. I suspect that it was something related to corrupted Visual Studio Settings, and changing the theme fixed the issue by recreating the settings file. Essentially, this is like a less destructive form or resetting Visual Studio settings, as it preserved all of my existing settings.
  • afterxleep
    afterxleep about 6 years
    Or rather in VS 2015, Tools -> Options -> Environment -> Fonts and Colors. For me the foreground/background was already set to what it should have been, but I clicked OK and restarted regardless and then restarted, and the display was then visible.
  • Siegfried.V
    Siegfried.V over 5 years
    Same for me, for me I guess it is a Windows automatic update the cause of it, as it restarted my computer by night, and VS was opened.