How do I change the folder of my existing solution file (sln)?
It's right now inside one of my project's folder; if I cut the solution file and paste it in the root folder,it doesn't load any of my projects.
In Visual Studio, click Tools > Options. Expand Projects and Solutions and click Locations. The Projects location field defines the default location for storing new projects. You can change this path if you are using a different working folder.
In the Solution Explorer window, right-click and select Remove to remove a project from a solution. Right-click the solution (top node) and select Add > Existing Project to add a project to a solution. Thank you.
Creating Solution Folders To create a folder within the solution, right-click the solution name in the Solution Explorer pane and choose "Add", then "New Solution Folder" from the context-sensitive menu. To create a subfolder, start by right-clicking an existing solution folder and then choose the same menu options.
Click on the options menu (the vertical ellipsis) in the row and click Move. Click Browse to select the folder to which you want to move the project. Click Move.
Open solution explorer in Visual Studio and select the solution.
Click on File > Save MyProject.sln As ...
and choose the new location.
The solution file is just a text file. You should be able to move it and then edit it to make sure that any relative paths referenced in the file are correct.
I've also been able to right-click on the solution file in the solution explorer and then use save-as to save it in a different location. That doesn't seem to work everytime for me though.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With