Configuration With Same Name Already Exists
Solution 1
Make sure you're using the drop down list from the grid (not the one at the top of the dialog), and do not check the "Create new solution configurations" checkbox when adding your new project configuration.
Solution 2
Here's a workaround if already checked the Create new solution configurations checkbox:
- Open Explorer and navigate to the location of the solution for the project that is missing platforms.
- Move the solution .sln file to a temorary location where Visual Studio won't locate it.
- Open the .csproj file for the project that is missing platforms.
- Click the Solutions Platform dropdown.
- Click Configuration Manager...
- In the table, Click the dropdown in the Platform column for the project and select , to add a new platform.
- Click OK.
- Repeat adding new platforms as needed.
- Save the project.
- Return the previously moved solution file back to where it was.
- Reopen the combined project solution.
Solution 3
The above solution didn't quite work, but I did find a solution on a forum that worked. Described below is to set the builds to x64 for each project that was set to "Any CPU", but the steps would also work for x86.
-
Open the main solution. Unload each project with a conflict (not remove).
-
Leave the solution open.
-
In Explorer, navigate to the project folders and open the csproj file in Visual Studio.
-
In this screwed up project, navigate to Build->Configuration Manager.
-
If needed, "Add New" and set it to x64 and save.
-
Right-click the project and set the build architecture to the new x64.
-
Save this, but when you close the project in VS, do not save to the solution. That's unnecessary.
-
Repeat for each project with a misaligned architecture.
-
Finally, in the original solution with all the offending projects, reload each project.
-
Open the Build->Configuration Manager for the solution. Then, one by one, reset "Any CPU" to the desired platform, in my case x64.
Save the changes for the solution and rebuild all. You should be OK, now.
Josh M.
Avid C#/.NET software engineer, database developer, UI/UX designer. Check out CodeGenerator - generate 90% of your code. Any language, any framework.
Updated on July 01, 2021Comments
-
Josh M. almost 3 years
I have a solution with 10+ projects (VS2010 SP1). I have the following configurations defined in the solution:
- Debug
- Debug-QA
- Release-UAT
- Release-Production
This allows me to easily setup specific settings for each deployment scenario. However, for some reason I can't get things setup as I'd like. Please see this screenshot:
Notice the highlighted projects/configurations. I am unable to create a "Debug-QA" configuration for these projects (by selecting
<New>
in the cell for that particular project). When I try to add a new "Debug-QA" configuration to the DataUtility project, for instance, Visual Studio yells at me:This configuration could not be created because a solution configuration of the same name already exists.
I know it does! I'm trying to add the configuration to the project! What am I missing here? I want all projects to have all 5 configuration. I have the same problem when trying to match up (create) platforms (for instance, adding an "Any CPU" platform to the DataUtility project).
-
Rebecca about 10 yearsPossibly the most overlooked checkbox in Visual Studio!
-
bbqchickenrobot about 10 yearsYears has this plagued me. It only rears it's ugly head every couple years or so but, alas, a solution!! lol
-
Vikram about 10 years'Create new solution configurations' checkbox was causing the issue for me. Thanks for the solution!!!
-
Declan over 9 yearsMy issue was the "Create new solution configurations" checkbox. It seems unnecessary.
-
Kell over 8 yearsWhat the?! Somebody at microsoft must do a course in UI development. gah!
-
JamesFaix over 7 yearsWhat a devilish checkbox! Thanks Adam!
-
m93a about 7 yearsVote for its removal on VisualStudio Uservoice! It's your future too!
-
John Pittaway over 6 yearsHad this on VS2007 Community Edition. The "Create new solution configurations" checkbox was checked. I unchecked it as per Adam's suggestion and it worked just fine.
-
Swiss Frank about 3 yearsOn Visual Studio 2017 the problem remains, and it is called "Create new solution platforms".
-
WWZee about 3 yearsI have attempted this without that checkbox clicked and it looks like it succeeds but I still don't have the new option in the drop down