C # windows configuration file

I created a C # .net Windows Service that has a configuration file in it.

I read the configuration file settings from my code using

string setting1 = Properties.Settings.Default.setting1;

If I change the value of parameter1 directly in the Windows service .config file, for some reason it supports the value that I set for it during development in the project settings dialog box.

I do not understand what I am doing wrong.

thanks

+5
source share
2 answers

You have settings as user area instead of application area.

AppData . AppData , Windows.

+1

? , .

, ,

, , , , :

Properties.Settings.Default.Reload();

FileSystemWatcher .

0

All Articles