-1

Is it posible to re-cache app.config? for example after changing some fields in app.config do not restart application.

Thanks.

hovkar
  • 1,261
  • 3
  • 13
  • 21

2 Answers2

2

Have a look at this answer: Change connection string & reload app.config at run time

Community
  • 1
  • 1
Simeon
  • 5,443
  • 3
  • 27
  • 50
0

You can refresh certain sections of the configuration file using the ConfigurationManager class so the next time that section needs to be read, it's pulled from disk.

http://msdn.microsoft.com/en-us/library/system.configuration.configurationmanager.refreshsection%28VS.80%29.aspx

Andy Shellam
  • 14,945
  • 1
  • 25
  • 41