简体   繁体   English

Visual Studio 2015项目存在,但不再显示在解决方案资源管理器中

[英]Visual Studio 2015 Project exists but no longer shown in Solution Explorer

I have one solution that has been effectively cloned from another one. 我有一种已从另一种有效克隆的解决方案。 The cloned solution works fine but the original has mysteriously stopped working. 克隆的解决方案可以正常工作,但是原始解决方案神秘地停止了工作。

The solution file contains the project 解决方案文件包含项目

Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "CMS", "CMS\CMS.csproj", "{0EABB8B8-2784-4BBA-B2E8-5D7B4A302182}"
EndProject

And the CMS.csproj project file appears in the CMS subfolder. CMS.csproj项目文件将出现在CMS子文件夹中。

But the project doesn't appear in Solution Explorer when I load the solution. 但是在加载解决方案时,该项目没有出现在解决方案资源管理器中。 Effectively the solution is empty. 实际上,解决方案是空的。

I can load the project file directly, and VS will then show it in solution explorer inside a solution with the same name as the project. 我可以直接加载项目文件,然后VS将在与该项目同名的解决方案中的解决方案资源管理器中显示该文件。 But I don't understand why my original solution is not working. 但是我不明白为什么我原来的解决方案不起作用。 There are no error messages. 没有错误消息。

Does anyone have any ideas? 有人有什么想法吗?

Well, I've worked out the solution, but the answer just poses another bunch of questions. 好了,我已经解决了这个问题,但是答案只是提出了另外一堆问题。

Comparing the .suo file of the two projects, I found that the one that doesn't work has had an extra level of indentation added (ie a tab character in front of each line). 比较两个项目的.suo文件,我发现一个不起作用的文件添加了额外的缩进级别(即,每行前面的制表符)。 See below. 见下文。

When I took these extra tabs out, the Project reappeared in the solution explorer. 当我取出这些额外的选项卡时,该项目重新出现在解决方案资源管理器中。

This poses the following two questions (if you have any ideas, please add them in the comments)... 这提出了以下两个问题(如果您有任何想法,请在评论中添加它们)...

I haven't edited the .suo file. 我尚未编辑.suo文件。 Ever. 曾经 How did these tabs get added? 这些标签是如何添加的?

Given that the .suo file already contains tabs to indent sections. 假设.suo文件已经包含用于缩进部分的选项卡。 And given that the sections are clearly defined by [SectionName] End[SectionName] statements, why would Visual Studio not simply ignore the tabs? 鉴于这些节是由[SectionName] End [SectionName]语句明确定义的,为什么Visual Studio不能简单地忽略选项卡?

    Microsoft Visual Studio Solution File, Format Version 12.00
    # Visual Studio 14
    VisualStudioVersion = 14.0.24720.0
    MinimumVisualStudioVersion = 10.0.40219.1
    Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "CMS", "CMS\CMS.csproj", "{0EABB8B8-2784-4BBA-B2E8-5D7B4A302182}"
    EndProject
    Global
        GlobalSection(SolutionConfigurationPlatforms) = preSolution
            Debug|Any CPU = Debug|Any CPU
            Release|Any CPU = Release|Any CPU
        EndGlobalSection
        GlobalSection(ProjectConfigurationPlatforms) = postSolution
            {0EABB8B8-2784-4BBA-B2E8-5D7B4A302182}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
            {0EABB8B8-2784-4BBA-B2E8-5D7B4A302182}.Debug|Any CPU.Build.0 = Debug|Any CPU
            {0EABB8B8-2784-4BBA-B2E8-5D7B4A302182}.Release|Any CPU.ActiveCfg = Release|Any CPU
            {0EABB8B8-2784-4BBA-B2E8-5D7B4A302182}.Release|Any CPU.Build.0 = Release|Any CPU
        EndGlobalSection
        GlobalSection(SolutionProperties) = preSolution
            HideSolutionNode = FALSE
        EndGlobalSection
    EndGlobal

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 在 Visual Studio 2015 中重新加载项目后如何保留“新的解决方案资源管理器视图”? - How to keep “new solution explorer views” after reload a project in Visual Studio 2015? Visual Studio 2015解决方案资源管理器不刷新文件? - Visual studio 2015 solution explorer doesn't refresh files? 在Visual Studio 2015中更改解决方案资源管理器工具窗口的标题 - Changing the title of the Solution Explorer tool window in visual studio 2015 Visual Studio 2015解决方案资源管理器树视图中缺少文件图标 - File Icons are missing in Visual Studio 2015 Solution Explorer Tree View Visual Studio 2015 - 缺少解决方案资源管理器分支中的内容 - Visual Studio 2015 - missing content in solution explorer branches Visual Studio 2015 项目不再在调试模式下运行 - Visual Studio 2015 project no longer runs in debug mode VS2015中未显示Visual Studio Web项目 - Visual Studio Web Project does not shown on VS2015 添加Makefile项目到Visual Studio 2015解决方案总是过时的 - Added Makefile project to Visual Studio 2015 solution is always out of date Visual Studio 2015-如何从另一个解决方案引用项目? - Visual Studio 2015 - How to reference a project from another solution? 使用项目而不是解决方案中的程序包停止Visual Studio 2015 - Stop Visual Studio 2015 using project instead of package in solution
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM