摘要: 1、在VS中建立windows service后,应该添加一个安装程序。2、在默认的Service1.cs设计界面右键,添加安装程序,生成ProjectInstaller。包含两个类serviceProcessInstaller和serviceInstaller。3、前者的属性Account一般应设为LocalSystem。4、如需要计时器,不应使用winform的计时器,而是System.Timers.Timer。于是在Service1.cs中添加私有变量: private System.Timers.Timer timer;然后在初始化时: private void Initialize. 阅读全文
posted @ 2014-04-01 18:34 瓜王 阅读(224) 评论(0) 推荐(0)