Centralized Config file for DAAB

Topics: General discussion
Dec 21, 2008 at 11:32 PM

Can I tell DAAB to look at a Config Setting somewhere other than the .exe.config?

In a software project, if there are several modules (.exe) using DAAB, I have to configure quite a number of .exe.config for the same Config Setting, e.g. Connection String. Is there a simple way where I could tell DAAB to look for its setting at a centralized location?

Dec 22, 2008 at 9:33 AM

You can try doing it programmatically. Using the IConfigurationSource, similar to this.


IConfigurationSource source = new FileConfigurationSource(@"C:\DAAB.config");



DatabaseProviderFactory provider = new DatabaseProviderFactory(source);



Database db = provider.Create("YourConnectionStringName");

Valiant Dudan
Global Technology & Solutions
Avanade, Inc.