C#:制作同时安装WPF应用程序(ClickOnce)和Windows服务的安装程序 [英] C#: Making an Installer that installs both a WPF application (ClickOnce) and a Windows Service

查看:198
本文介绍了C#:制作同时安装WPF应用程序(ClickOnce)和Windows服务的安装程序的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我目前有一个包含2个项目的VS解决方案:WPF应用程序和Windows服务。



现在,我设法让ClickOnce可以安装WPF应用程序,但是我也希望在此安装过程中安装Windows Service(项目中的Windows Service)。



我已经找到了使用C#代码以编程方式启动Windows服务的方法,但是有什么方法可以将其合并到我的ClickOnce安装中(因为我需要ClickOnce的好处)自动更新等)?

解决方案

我认为您无法以正常方式通过ClickOnce部署Windows服务。 / p>

http://social.msdn.microsoft.com/Forums/zh-CN/winformssetup/thread/1bb64760-9622-4ca6-a1a6-3ce53e641f21



ClickOnce部署Windows服务吗?


I currently have a VS Solution with 2 projects: a WPF application and a Windows Service.

Now, I have managed to get ClickOnce working in installing my WPF application, but I also want a Windows Service to be installed (the one in the project) during this installation.

I have found ways how to programmatically start a windows service with C# code, but is there any way to incorporate this in my ClickOnce installation (because I need ClickOnce's benefit of automatic updates and such)?

解决方案

I don't think you can deploy a windows service via ClickOnce in a normal fashion.

http://social.msdn.microsoft.com/Forums/en-US/winformssetup/thread/1bb64760-9622-4ca6-a1a6-3ce53e641f21

ClickOnce deploy a Windows Service?

这篇关于C#:制作同时安装WPF应用程序(ClickOnce)和Windows服务的安装程序的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆