The OutputPath property is not set for this project

前端 未结 20 1490
無奈伤痛
無奈伤痛 2020-11-30 23:20

When I try to compile my project from x86 debug mode in Visual Studio 2008. I am getting this error. When I looked at the property group of the project that complained, I se

相关标签:
20条回答
  • 2020-11-30 23:38

    I got this problem after adding a new platform to my project. In my case .csproj file was under Perforce source control and was read-only. I checked it out but VS didn't catch the change until I restarted it.

    0 讨论(0)
  • 2020-11-30 23:39

    Another cause: you add a project reference from project A to project B in solution X. However, solution Y that already contains project A is now broken, until you also add project B to solution Y.

    0 讨论(0)
  • 2020-11-30 23:42

    I had the same problem after I have added new configurations and deleted the "debug" and "release" configs. In my case I was using a cmd file to run the build and publish process, but the same error was thrown. The solution for me: In the csproj file the following:

    <Configuration Condition=" '$(Configuration)' == '' ">Debug< /Configuration>
    

    was setting the Configuration to "Debug" if I did not specify an explicit one. After changing the node value from "debug" to my custom configuration, it all worked smoothly. Hope this will also help whoever is reading this :)

    0 讨论(0)
  • 2020-11-30 23:43

    The error shown in visual studio for the project (Let's say A) does not have issues. When I looked at the output window for the build line by line for each project, I saw that it was complaining about another project (B) that had been referred as assembly in project A. Project B added into the solution. But it had not been referred in the project A as project reference instead as assembly reference from different location. That location contains the assembly which compiled for Platform AnyCpu. Then I removed the assembly reference from the project A and added project B as a reference. It started compiling. Not sure though how this fix worked.

    0 讨论(0)
  • 2020-11-30 23:43

    I had the same problem, Just edit the .wixproj to have all of the <PropertyGroup Condition=" '$(Configuration)|$(Platform)' ... > elements to be side by side.

    That solved my issue

    0 讨论(0)
  • 2020-11-30 23:44

    Another crazy possibility: If you follow a simple source control arrangement of putting Branch\Main, Main, and Release next to each other and you somehow end up adding an existing project from Main instead of Branch\Main (assuming your working solution is Branch\Main), you may see this error.

    The solution is simple: reference the right project!

    0 讨论(0)
提交回复
热议问题