ConfigurationSettings.AppSettings always uses configuration file of actual app. domain that is in your case the assembly performing Assembly.Load() To load configuration from configuration file named according to your loaded assembly you need to write the process for your own or use something like this: http://www.bearcanyon.com/dotnet/AssemblySettings.zip
-----Original Message----- From: Bogdan Lachendro [mailto:[EMAIL PROTECTED] Sent: Wednesday, January 28, 2004 11:39 AM To: [EMAIL PROTECTED] Subject: [ADVANCED-DOTNET] Assembly.Load() and app.config Hi, I have a problem with loading assemblies using reflection and reading configuration files. I load an assembly using Assembly.Load() method. Then I invoke a method from that assembly. This method calls System.Configuration.ConfigurationSettings.AppSettings["MyKey"] and the result of that call is always null. Is there any way to make my (loaded using reflection) assembly to read it's app.config file ?? Thanks and Best Regards, Bogdan =================================== This list is hosted by DevelopMentorŽ http://www.develop.com Some .NET courses you may be interested in: NEW! Guerrilla ASP.NET, 26 Jan 2004, in Los Angeles http://www.develop.com/courses/gaspdotnetls View archives and manage your subscription(s) at http://discuss.develop.com =================================== This list is hosted by DevelopMentorŽ http://www.develop.com Some .NET courses you may be interested in: NEW! Guerrilla ASP.NET, 26 Jan 2004, in Los Angeles http://www.develop.com/courses/gaspdotnetls View archives and manage your subscription(s) at http://discuss.develop.com
