Windows Service and app.config

  • Thread starter Thread starter Bill
  • Start date Start date
B

Bill

I've created a windows service in C#, but I'm having trouble reading
<appSettings> from a app.config file.

I can read <appSettings> just fine from a normal C# windows app, so there
must be some trick to read this file from a windows service, yes? perhaps
the location of the .config file?

any help is appreciated...
-bill
 
I don't think app.config is designed to work with a dll (or a service).
You can store the configuration in an Xml (you'll do the parsing)
or in the registry.
 
App.config works just fine with Windows Services, there is no need for a
custom xml file.
 
Back
Top