为什么Visual Studio阻止我看到.csproj文件,有没有办法强制它打开?

B. *_*non 17 notepad++ csproj web-development-server visual-studio-2013

当我寻找我的Web API使用的端口号的硬编码来源时,我在项目的*.csproj文件中找到了它.然而,当我在Visual Studio中的"查找结果"窗口中双击它时,它将无法打开,而且我非常了解情况," 文档'Bla*.csproj'已作为项目或解决方案打开,不能是此时在编辑中打开了. "

要看一下,我必须用Notepad ++打开它,它会告诉我我想要的东西:

<WebProjectProperties>
  <UseIIS>True</UseIIS>
  <AutoAssignPort>True</AutoAssignPort>
  <DevelopmentServerPort>28642</DevelopmentServerPort>
  <DevelopmentServerVPath>/</DevelopmentServerVPath>
  <IISUrl>http://localhost:28642/</IISUrl>
  <NTLMAuthentication>False</NTLMAuthentication>
  <UseCustomServer>False</UseCustomServer>
  <CustomServerUrl>
  </CustomServerUrl>
  <SaveServerSettingsInUserFile>False</SaveServerSettingsInUserFile>
</WebProjectProperties>
Run Code Online (Sandbox Code Playgroud)

......但这有点痛苦.有没有更快的方法从项目/ Visual Studio(2013)中打开.csproj文件?

Soo*_*Tan 42

要直接从Visual Studio编辑.csproj(或任何其他项目文件),请执行以下操作:

  1. 在Solution Explorer中右键单击该项目
  2. 选择"卸载项目"
  3. 项目现已卸载
  4. 再次右键单击该项目,然后选择"编辑blah.csproj"
  5. 进行更改并保存
  6. 右键单击项目,然后选择"重新加载项目"以应用更改