开发者

How to modify Windows service configuration file after installation?

I deployed a Windows service built with Visual Studio 2008. My service project has a app.config file where I put the configuration of the service. When my service has been installed, this app.config file became service.exe.config. I'm trying to modify this file, but the system informs me is in use, even when the service is currently stoped开发者_如何学C.


I too had this problem and I found that if I opened Notepad as Administrator then opened the config file, I could save changes while the service was installed and stopped. If you have custom config sections, you probably want to make sure your service reloads them in the OnStart.


Temporarily turn automatic service start off (to manual) and reboot...then edit your file.

Unlocker can also be your friend

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜