问题
When I am opening a .sln in Visual Studio 2010, projects are loading properly. But when I open the same solution with Visual Studio 2015 (Professional with Update 1), projects are not getting loaded with the error (load failed). This is shown below:
Can anyone suggest the solution for this?
回答1:
I've already had this problem and in my case I solved it by executing VS as Administrator.
回答2:
I experienced this issue for different reasons , but deleting all of the .vs folders ( there was one at the solution level and some projects had their own ) worked for me .
How To: Close the solution , delete all the .vs folders , reopen the solution .
回答3:
Try the following:
Open the
Output
window (View
->Output
orCtrl+Alt+O
).Then right-click one of the failed projects and select
Reload Project
.
The Output
window will now show a more detailed error message.
回答4:
Try deleting .suo & .user files.
http://www.howtosolutions.net/2013/02/solving-project-file-error-could-not-find-part-of-the-path-with-visual-studio/
For those who receive this error but did not move projects around
Try deleting .suo files in your solution folder. Solution User Option file is a binary file which contains various user information and settings such as location of the breakpoints.
If that didn't help try also to delete .user file. If you have trouble finding .suo file
In Visual Studio 2015 (also in Community Edition), the .suo file is located inside a hidden .vs folder in solution folder. Since both .vs folder and .suo file have hidden attribute applied to them, you have to reveal them using using File Explorer by changing folder options to “show hidden files, folders and drives”. How to get to this option in File Explorer depends on the version of Windows:
- In Windows 7, option is located under Organize > Folder and search options.
- in Windows 8, it is located under View tab > Options > Change folder and search options.
- in Windows 10, it is the same as in Windows 8.
回答5:
I opened the .sln (MySolutionName.sln) file with Notepad++ and edited the below parts. I had 3 projects in my solution:
MyProject1Name, MyProject2Name, MyProject3Name
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "MyProject1Name", "MySolutionName\MyProject1Name.csproj", "{D9FA9D42-71F3-459E-9643-426F002713EE}" EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "MyProject2Name.Service", "MyProject2Name\MyProject2Name.csproj", "{173F0709-90E3-48B9-AA06-4AEC9957AFED}" EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "MyProject3Name", "MyProject3Name\MyProject3Name.csproj", "{B5F4ADAC-7C37-4A2C-B15A-56C50F3BF7C9}" EndProject
then everything worked properly and the projects load successfully.
回答6:
You may need to correct the Projects Path to match new environment. Please see below post to see how to do it.
http://www.howtosolutions.net/2013/02/solving-project-file-error-could-not-find-part-of-the-path-with-visual-studio/
回答7:
Right click on the file which failed to load and reload it ,it worked in mine case
回答8:
I had this issue where a colleague could not open the solution that contained many projects. I had previously migrated the solution from VS2013 to VS2015 and I had no issues with projects loading once opening the solution.
The fix was to install SSDT for VS2015 https://docs.microsoft.com/en-us/sql/ssdt/download-sql-server-data-tools-ssdt#ssdt-for-visual-studio-2015
This allowed for all the projects to load correctly within the solution.
回答9:
deleting .vs files worked for me also. I can now able to rename project file. I am using VS 2017
回答10:
Our project was configured to use Local IIS and in our case it was needed to run Visual Studio as Administrator and only then the project loaded...
回答11:
1- Open .sln file in notepad
2- Change path/name of your project
3-Open Visual studio
4- Right click project and Remove.
5- Right click solution and add project again.
回答12:
I had the same problem with a web-project, solved it by deleting applicationhost.config from the .vs\config folder.
I recently enabled SSL for that project, and then disabled it again by undoing the changes from another solution, I suspect its related to that.
回答13:
Right click on on the project which was failed and select reload option from context menu, The screen will pop up which is related to permission, uncheck the check box and continue. It is noticed that initialization and loading of project will happen properly
回答14:
I had a global.json file with a defined dotnet core sdk version that wasn't installed.
I removed the global.json and it worked.
I then looked up my sdk versions and returned the global.json but updated the version in it. Alternatively, you can just install the required sdk.
回答15:
If you are having issues with project loading failed, like this:
The first thing you need to do is to fix all of the other issues you are having. The next step is to check the project .csproj file.
In my case, the issue was <TargetLatestRuntimePatch>true</TargetLatestRuntimePatch>
You mind have another issue, just carefully check the file.
So I deleted the issue line and reloaded the project, and it works just fine every time.
回答16:
In my case, this issue occurred after I renamed and moved around a few projects in my solution. What worked in my case was a simple removal of those project files and then re-adding them from the 'Solution Explorer'. Sharing a handy link with screenshots that might be of help.
回答17:
Please try with any of this VS2015/2019
来源:https://stackoverflow.com/questions/42201920/projects-load-failed-in-visual-studio-2015