Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Change application settings for a deployed class library?

If I define application level settings (using Properties.Settings) within a class library, can I change those settings once that dll is deployed to an app? If so, how? Do I just create the equivalent setting in web.config to override it?

like image 791
Jeremy Avatar asked Jun 12 '26 10:06

Jeremy


1 Answers

I found that you have to declare a section for the class library dll in the web.config. So, if your namespace is "Company.Application.DataLayer" you would need to have a "Company.Application.DataLayer.Properties.Settings" section declared within your "applicationSettings" section.

Note: To have that section be recognized, you must also declare it within the applicationsettings sectionGroup of your web.config.

like image 156
Jeremy Avatar answered Jun 14 '26 23:06

Jeremy