打开项目文件,查找如下配置节定义:
<Import Project="$(MSBuildExtensionsPath32)\Microsoft\VisualStudio\v10.0\WebApplications\Microsoft.WebApplication.targets" />
确认是否符合XML规范,比如下面的错误定义:
<Import Project="$(MSBuildExtensionsPath32)\Microsoft\VisualStudio\v10.0\WebApplications\Microsoft.WebApplication.targets" Condition="false" /> />
可以参考 http://connect.microsoft.com/VisualStudio/feedback/details/504726/msbuild-target-pipelinepredeploycopyallfilestoonefolder-cannot-be-found-when-deploying 的Workarounds。