I'm trying to abstract out all database code into a separate library and then use that library in all my code. All database connections are done using typed TableAdapters that I create by dragging and dropping in datasets in VS2005, using a connection string from the appSettings.
The problem that I haven't been able to solve is that .Net doesn't propagate the libraries appSettings to the other project that's using it.
In short, I have a database layer library, MyProgram.DbLayer, which is used by other projects such as MyProgram.Client etc. When I had all the datasets in the .Client the connectionString was in MyProgram.Client.exe.config so that I could change it after build. When I moved it into the MyProgram.DbLayer that setting isn't avaliable to me after I build the binaries.
EDIT: This seems to be a more general issue with ApplicationSettings.
What I noticed was that if I manually add a setting only used in a library it will be properly read. The only thing I need now is for the setting to be automatically included in the .config file as well.