Project GUID keeps changing

后端 未结 6 1891
深忆病人
深忆病人 2021-01-07 16:24

We have a VS2008 solution and i\'ve noticed something weird happening:

some projects refer other projects that are defined in the same solution (added as project ref

6条回答
  •  醉酒成梦
    2021-01-07 17:02

    This happens if you have two projects with the same guid in the same solution, VS will assign a new guid to one of them. And that can be happen when a new solution with a new Project is build and if you insert shared projects they may have a guid that is the same like the new project. The problem is that all other solutions which have also the shared project already inserted have to change the guid again and thats annoyingly.

    A simple Solution instead of editing the solution-/project-files by hand: Just remove the projects and then insert the shared projects FIRST and AFTER THAT insert the NEW project. So VS gives a new - not duplicate - guid to the new project and is not forced to change the guid of the shared projects.

    ... so much for the topic "Globally Unique Identifier" ;-)

提交回复
热议问题