question

JohnCouch-7779 avatar image
0 Votes"
JohnCouch-7779 asked Viorel-1 answered

System.Configuration Reference missing in Visual Studio 2019

I am trying to add a reference to System.Configuration to make use of the Configuration Manager in Visual Studio 2019 but its not there. I tried browsing to it, but can't find it.

vs-general
· 2
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.


What kind of project did you create?

0 Votes 0 ·

C# Windows Form using .Net 5.0 Current. I also tried using .Net core 3.1. neither worked.

0 Votes 0 ·

1 Answer

Viorel-1 avatar image
2 Votes"
Viorel-1 answered

I think that System.Configuration.ConfigurationManager is available in this case. To add more types and packages, use “Manage NuGet Packages…” window. Search for “System.Configuration” in Browse tab.


· 2
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

No offense to anyone, but this is ridiculously dumb that you now have to add everything individually vs. just adding a reference to it. VS 2015 was so much cleaner and easier to use. Apparently every DLL you want to add a reference too you now have to pull the NuGet package for, even the basics.

Viorel - Thanks for taking the time to give me some direction. I was expecting it to just be there like it used to be. Appreciate the help.

0 Votes 0 ·

Hi @JohnCouch-7779 , welcome to Microsoft Q&A forum. I tested on my side and it seems the ConfigurationManager class(`System.Configuration`) can be used in VS 2019( Winform, .Net 5.0) without installing NuGet packages or adding references. I noticed that for several project templates, it is needed to manually reference it, but perhaps not for Winform(.NET 5.0) project. If you didn’t try it, you can have a try to directly use it by adding using System.Configuration;. If you can't directly use it, could you share me the detailed steps to reproduce this issue?

BTW, I'm happy to hear that Viorel's suggestion work for you.

0 Votes 0 ·