简体   繁体   English

在 Visual Studio 2022 上为 windows 服务创建安装程序

[英]Creating an installer for a windows service on Visual Studio 2022

typically I don't work with VS and C#, but my company requires it for this project.通常我不使用 VS 和 C#,但我的公司在这个项目中需要它。 So kinda new on this stuff.这东西有点新。

I got some code from a previous developer, which is just a .net service doing some stuff.我从以前的开发人员那里得到了一些代码,这只是一个 .net 服务做一些事情。 Som adjustment had been done in the code my me, not a problem at this point.我的代码中已经完成了一些调整,此时不是问题。

But here comes the trick: I need to create an installer, .exe or.msi file, which installs the service on the windows machine where it get's executed.但诀窍来了:我需要创建一个安装程序,.exe 或 .msi 文件,它将服务安装在执行它的 windows 机器上。 I tried so much, googled my ass off but nothing did the work for me.我尝试了很多,用谷歌搜索了我的屁股,但对我没有任何帮助。

Is there anyone that can help and explain, step for step, what I need to do in VS?有没有人可以帮助和解释,一步一步,我需要在 VS 中做什么?

Very much thanks in advance!非常感谢提前!

I highly recommend the WiX Toolset to create an MSI for installing a Windows service.我强烈推荐 WiX 工具集来创建用于安装 Windows 服务的 MSI。 This tutorial takes you through the process from end-to-end, including setting up your development environment for WiX. 本教程将引导您完成整个过程,包括为 WiX 设置开发环境。 You can see their service install documentation for a high-level overview.您可以查看他们的服务安装文档以获得高级概述。 Also, this StackOverflow question is an excellent resource.此外, 这个 StackOverflow 问题是一个很好的资源。

If you run into issues, I'm happy to help address them.如果您遇到问题,我很乐意帮助您解决问题。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 将参数发送到Windows Service Installer Visual Studio - Send parameters to Windows Service Installer Visual Studio 如果由 Visual Studio 安装程序安装,则无法调试 Windows 服务 - Can't debug Windows Service if it's installed by Visual Studio Installer 如何使用Visual Studio为.net Windows服务创建安装程序 - How to create an installer for a .net Windows Service using Visual Studio 在Visual Studio 2013中创建安装程序 - Creating installer in Visual Studio 2013 如何使用 Visual Studio 安装程序项目安装 .NET 6 Windows 服务(Worker Service)? - How do you install a .NET 6 Windows Service (Worker Service) using a Visual Studio Installer project? Visual Studio安装程序未创建.msi文件 - Visual Studio Installer not creating .msi file Visual Studio安装程序项目扩展-安装服务 - Visual Studio Installer Projects Extension - Install a Service Visual Studio 2017 中的 Windows 安装程序项目 - Windows Installer Project in Visual Studio 2017 Windows 10 上的 Visual Studio 安装程序公司名称 - Visual Studio Installer company name on Windows 10 适用于 Windows XP 的 Visual Studio 2013 安装程序 - visual studio 2013 installer for windows xp
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM