.Net 2.0 I have a variety of console applications that run continuiously in
parallel using the file watcher as an event queue. In addition, I have an
ASP.Net website that needs to access the same key/value pairs as the console
apps. I have configured a separate app.config file for each console app and
have a separate web.config file for the web site. To simplify the
configuration, I would like to use a single app.config file that can be
accessed by each application. Is there a simple way to do this?

Thanks,
--
Tim Meagher

Re: How to use a shared app.config file? by Chris

Chris
Mon Oct 08 17:17:09 PDT 2007

A few things come to mind, none of which are probably what you're looking
for:

- Put the relevent entries in the machine.config. This way everything can
see them. This would be very, very easy.

- From your main entry point, create a new appdomain and set it's config
file to be the shared config file. Set the entry point to be the relevant
code, and let your code start running.

- Store the data in a database, and read it from each app.

- Store the data in an XML file somewhere, and just have each app open the
file and read the values out.

--
Chris Mullins

"AAOM Tim" <AAOMTim@discussions.microsoft.com> wrote in message
news:C4368B53-426F-477F-B4BC-31B7234AEFA0@microsoft.com...
> .Net 2.0 I have a variety of console applications that run continuiously
> in
> parallel using the file watcher as an event queue. In addition, I have an
> ASP.Net website that needs to access the same key/value pairs as the
> console
> apps. I have configured a separate app.config file for each console app
> and
> have a separate web.config file for the web site. To simplify the
> configuration, I would like to use a single app.config file that can be
> accessed by each application. Is there a simple way to do this?
>
> Thanks,
> --
> Tim Meagher