警告 Visual Studio:无法读取与解决方案关联的某些属性

Warning Visual Studio: Some of the properties associated with the solution could not be read

我将此发布为许多建议的修复程序,例如查看 [GlobalSection(TeamFoundationVersionControl)] 是否重复并删除它、重命名解决方案以强制重建以及在 visual studio 中重建解决方案。但是,其中 none 有效。受影响的解决方案发布在下面。 (这真的很烦人,因为它也没有保存我的发布配置的构建 属性)而且我知道它与被复制的 GlobalSection(SolutionConfigurationPlatforms) = preSolution 有关,但我不知道如何解决这个问题.. .

Microsoft Visual Studio Solution File, Format Version 12.00
# Visual Studio 2013
VisualStudioVersion = 12.0.40629.0
MinimumVisualStudioVersion = 10.0.40219.1
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "DroidKit OnePlus One", "DroidKit OnePlus One\DroidKit OnePlus One.csproj", "{325DC736-70A1-422D-A4B9-441E228C5062}"
EndProject
Global
    GlobalSection(SolutionConfigurationPlatforms) = preSolution
        Debug|Any CPU = Debug|Any CPU
        Debug|Default = Debug|Default
        Release|Any CPU = Release|Any CPU
        Release|Default = Release|Default
    EndGlobalSection
    GlobalSection(ProjectConfigurationPlatforms) = postSolution
        {325DC736-70A1-422D-A4B9-441E228C5062}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
        {325DC736-70A1-422D-A4B9-441E228C5062}.Debug|Any CPU.Build.0 = Debug|Any CPU
        {325DC736-70A1-422D-A4B9-441E228C5062}.Debug|Default.ActiveCfg = Debug|Any CPU
        {325DC736-70A1-422D-A4B9-441E228C5062}.Release|Any CPU.ActiveCfg = Debug|Any CPU
        {325DC736-70A1-422D-A4B9-441E228C5062}.Release|Default.ActiveCfg = Debug|Any CPU
    EndGlobalSection
    GlobalSection(SolutionProperties) = preSolution
        HideSolutionNode = FALSE
    EndGlobalSection
    GlobalSection(SolutionConfigurationPlatforms) = preSolution
        Debug|Any CPU = Debug|Any CPU
        Debug|Default = Debug|Default
        Release|Any CPU = Release|Any CPU
        Release|Default = Release|Default
    EndGlobalSection
    GlobalSection(SolutionConfigurationPlatforms) = preSolution
        Debug|Any CPU = Debug|Any CPU
        Debug|Default = Debug|Default
        Release|Any CPU = Release|Any CPU
        Release|Default = Release|Default
    EndGlobalSection
EndGlobal

我有办法! 所以我所做的是创建另一个空项目。复制整个 Global 部分并将其粘贴到损坏的文件中。由于我不使用 Team Sever 或 Source 共享,所以很容易修复! 我复制的代码如下:

Global
    GlobalSection(SolutionConfigurationPlatforms) = preSolution
        Debug|Any CPU = Debug|Any CPU
        Debug|x64 = Debug|x64
        Debug|x86 = Debug|x86
        Release|Any CPU = Release|Any CPU
        Release|x64 = Release|x64
        Release|x86 = Release|x86
    EndGlobalSection
    GlobalSection(ProjectConfigurationPlatforms) = postSolution
        {325DC736-70A1-422D-A4B9-441E228C5062}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
        {325DC736-70A1-422D-A4B9-441E228C5062}.Debug|Any CPU.Build.0 = Debug|Any CPU
        {325DC736-70A1-422D-A4B9-441E228C5062}.Debug|x64.ActiveCfg = Debug|Any CPU
        {325DC736-70A1-422D-A4B9-441E228C5062}.Debug|x86.ActiveCfg = Debug|Any CPU
        {325DC736-70A1-422D-A4B9-441E228C5062}.Release|Any CPU.ActiveCfg = Release|Any CPU
        {325DC736-70A1-422D-A4B9-441E228C5062}.Release|Any CPU.Build.0 = Release|Any CPU
        {325DC736-70A1-422D-A4B9-441E228C5062}.Release|x64.ActiveCfg = Release|Any CPU
        {325DC736-70A1-422D-A4B9-441E228C5062}.Release|x86.ActiveCfg = Release|Any CPU
    EndGlobalSection
    GlobalSection(SolutionProperties) = preSolution
        HideSolutionNode = FALSE
    EndGlobalSection
EndGlobal