Share via

How to fix "Could not retrieve project assembly output path" after upgrading from .NET Framwork to .NET

יוסף שלי 15 Reputation points
2024-04-04T08:04:15.54+00:00

After upgrading from .NET Framework to .NET the program is working fine but when I try to edit a Form, Any Form, I get the same message on the yellow bar: "Could not retrieve project assembly output path. Parameter name hierarchy." Can anyone direct me to how to fix it and tell me why I got this error every time I tried to migrate?

Thanks.

User's image

Developer technologies | .NET | Other

3 answers

Sort by: Most helpful
  1. Martin Nilsson 5 Reputation points
    2024-10-24T07:43:57.5966667+00:00

    Hi

    I've had this error as well. The reason was that the build skipped the project containing the form (or in my case a user control) and that caused the error about not finding the output path.

    The solution was to manually correct the solution file (.sln) and make sure that the build settings were the same for all projects. (The Configuration Manager didn't indicate any problem!)

    	{922EC095-EC00-4254-832D-7552D59EBF2C}.Debug|x64.ActiveCfg = Debug|x64  
    	{922EC095-EC00-4254-832D-7552D59EBF2C}.Debug|x64.Build.0 = Debug|x64  
    	{922EC095-EC00-4254-832D-7552D59EBF2C}.Release|x64.ActiveCfg = Release|x64  
    	{922EC095-EC00-4254-832D-7552D59EBF2C}.Release|x64.Build.0 = Release|x64
    
    1 person found this answer helpful.

  2. Dale Hays 40 Reputation points
    2026-03-26T21:22:55.1866667+00:00

    RE: Visual Studio 2026, Winforms application

    I had the same problem after changing my 'TargetFrameworks' while attempting to move some projects over to .NET10. I had issues and rolled back to .NET8.0. Afterwards, on a specific project I had the above failure.

    The development solution has about 12 projects in it. Only one of them had the above error.

    Solution: I closed the solution and opened up just the one offending project file. Then I could load the form correctly and then saved it. I then closed the Project and re-opened the solution once again. I could now load forms from the Project that had previously failed.

    0 comments No comments

  3. Anonymous
    2024-04-04T09:30:35.98+00:00

    Hi @יוסף שלי , Welcome to Microsoft Q&A,

    There is a possibility that although it was migrated the path of the link did not change.

    1. Go to Manage Workspaces (either via the File/Source Control menu or the Workspace drop-down list in Source Control Explorer)
    2. Select Edit for the workspace.
    3. You should see a mapping of the source control directory under the "Working Folders" added to the old/wrong project directory.
    4. Select it and click Delete.
    5. Close VS and delete the suo file.

    It's still referencing the wrong directory, reload your project and you should be good to go.

    You can also try deleting the suo file directly and reloading it. The suo file may be hidden and you need to show it manually. Best Regards,

    Jiale


    If the answer is the right solution, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment". 

    Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.


Your answer

Answers can be marked as 'Accepted' by the question author and 'Recommended' by moderators, which helps users know the answer solved the author's problem.