You can create and a App.Config file in a Windows Service project but as I
have not actually tried wirking with it, I cannot be sure that it actually
works.
The App.Config file is structured like:
<?xml version="1.0" encoding="utf-8" ?>
<configuration>
<appSettings>
<add key="FilePath" value="C:\Path\" />
</appSettings>
</configuration>
And is accessed as follows:
Configuration.ConfigurationSettings.AppSettings("F ilePath")
"ia*******@gmail.com" wrote:
I just need a simple code snippet to read from a config file the file
locations needed for my Windows Service. Sort of like web.config but
since this is a Windows Service, I won't be using that.