output path ignored with .net 5 C# classes lib

Pasc059 1 Reputation point


I updated a .net framwework project (a library of windows forms controls in C#) to .net 5. Eveything seems ok except that the ouput path of the buid, specified in the project properties, is ignored. For instance, for the Debug config the ouput path is always 'bin\Debug\net5.0-windows' and 'bin\Release\net5.0-windows' for the Release config. I don't want vs2019ce (version 16.8.3) add/create the folder 'net5.0-windows'.

Is this a bug?


Windows Forms
Windows Forms
A set of .NET Framework managed libraries for developing graphical user interfaces.
1,823 questions
0 comments No comments
{count} votes

2 answers

Sort by: Most helpful
  1. Oleg Ra 1 Reputation point

    @Pasc059 If you use the new .csproj format (and most probably you do so) just add these lines into the project file:


    See more details here (in the Note section).

  2. Pasc059 1 Reputation point

    thank you Oleg, after inserting the lines you mentioned in the csproj file, this works as i want. Without specifying an output path, the defaults outputs are \bin\Debug and [bin\Release for respectively the Debug and Release configurations, which suits to me.


    0 comments No comments