Hi,
I'm not quite sure how .NET and C# 3.5 handles the settings of applications spanning over multiple projects as well as multiple solutions. Maybe someone can help me clear things up.
I've got 2 solutions, both containing several projects. Some of those projects contain a Setttings.settings file under the Properties folder, containing specific configuration variables required by the source files in this project.
Something like
- JobManager Solution
- Manager.Core (with settings file)
- Manager.UserInterface (with settings file)
- Manager.Extension
- Importer Solution
- Importer (with settings file)
- Service (with settings file)
As can be seen, Manager.Core
contains its own configuration file to store database connection information and other stuff, whereas the Importer
contains its own configuration files storing the paths to the import directories to know where to get the files it needs to import into the database using Manager.Core
to do so. (that's what Manager.Core is there for, it contains all the queries and inserts to work with the DB)
Service
, on the other hand, is a Windows Service which uses the Importer and let's it run every hour or so, containing its own configuration settings for error logging paths.
Now when I compile the Service, there is only 1 configuration file called Service.exe.config, containing only the configuration parameters specified in the Service project. My first approach was to duplicate every setting entry of Manager.Core and Importer in Service.exe.config. But testing showed that, somehow, the parameters of the Importer are present and used.
Where are the settings for Manager.Core
and Importer
stored when they are not present in Service.exe.config?
Are the settings of Manager.Core
present, too, meaning it's unnecessary to duplicate the entries of those configuration settings in the Service settings file?
Kind regards, Michael