Windows服务安装程序项目从VS.NET 2008转换为2010的问题

Bri*_*ian 2 .net installation windows-services visual-studio-2010 visual-studio-2008

我正在尝试将解决方案从VS.NET 2008转换为2010。该解决方案包括Windows Service项目和安装Windows Service的安装项目。我在编译安装项目时遇到问题。我试着从头几次启动该结束了,下面的教程在这里下节标题为要创建为您服务的安装项目

当我简单地按照以下步骤构建项目时,会出现以下错误:

Unable to build custom action named 'Primary output from <name> (Release x86)', InstallerClass property is only valid for assemblies.
Run Code Online (Sandbox Code Playgroud)

(我的Windows服务项目的名称在哪里)。搜索此错误会在MSDN 上显示页面,告诉我将InstallerClass设置为False。对于4种自定义操作,我都会这样做。进行更改并构建后,出现以下错误:

Unable to build custom action named 'Primary output from <name> (Release x86)' from project output group 'Primary output' because the project output group does not have a key file.
Run Code Online (Sandbox Code Playgroud)

为此,我一击未中。甚至不用担心单击链接,全文为:“删除自定义操作,并用指向具有密钥文件的项目输出组的自定义操作替换它。”

h是什么意思?有人可以帮我弄清楚我在做什么错吗?

Bri*_*ian 5

看来问题出在我将InstallerClass设置为False时。显然,我没有为x86目标构建Windows服务。我从这次讨论中得到了提示。我更改了所有项目,以针对正确的平台,并将安装程序文件中的每个“自定义操作”的InstallerClass设置为True,现在正在构建。