开发者

Simple installation of WindowsService

I'm having difficulty implementing a WindowsService with C# Express. What I want is to write a class that separates the installation logic from the service, er, service. To make this worthwhile I am looking to remove the class deriving from installer and be left with just the service itself, as I thought http://msdn.microsoft.com/en-us/library/zt39148a%28v=VS.100%29.aspx might describe. All these fancy install and packaging wizards are absent from my Express edn so I must use only .NET classes.

I'm considering Man开发者_高级运维agedInstallerClass and AssemblyInstaller and _not_ installutil, if at all possible.


Use the ManagedInstallerClass.

The answers in this question are excellent. Please check Self install windows service in .NET c# and the code midpage here http://blogs.microsoft.co.il/blogs/kim/archive/2009/01/04/self-installing-windows-service.aspx (this example uses AssemblyInstaller).

0

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜