Load App.Config data into a DLL

Here is my way of getting a DotNet DLL to load its app.config file.

AppDomain.CurrentDomain.SetData ("APP_CONFIG_FILE",ConfigFile);

Where ConfigFile is the full path to your application's app.config file.(c:\test\myapp.config)

As a side note you may need to call ConfigurationManager.RefreshSection

in order to see your values.
Comments [1]