Visual Studio自定义工具安装程序 [英] Visual Studio Custom Tool Installer

查看:104
本文介绍了Visual Studio自定义工具安装程序的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在尝试为自定义工具"创建一个安装项目, (即您可以在属性窗口中为项目文件设置的内容).我希望它可以同时与VS2008和VS2010一起使用,因此我引用了2008 SDK组件,它似乎可以正常工作 在我们的开发人员机器上(一个小问题除外,我将在后面描述).

现在,说我想部署我们的解决方案.我观看了有关部署VS软件包的视频教程( http://msdn.microsoft.com/en-us/vstudio/cc627235.aspx ),他只是排除了所有SDK 设置项目中的参考.如果您已经安装了2008 SDK,则效果很好,但是我不希望我们工具的用户仅使用我们的自定义工具就必须下载并安装100mb的软件包.是否有合并模块或我可以包含的东西 这样可以确保所有依赖项都可以通过我们的工具安装?

< p"小问题"我在上面提到过:当我尝试从标有[ComRegisterFunction]的静态方法(使用标准Microsoft.Win32注册表方法)添加适当的注册表项时,它会从"LocalMachine"重定向到到另一个文件夹 在"CurrentUser"中相反,VS找不到它所在的工具.

指定的原始路径:Registry.LocalMachine,"SOFTWARE \ Microsoft \ VisualStudio \ 10.0 \ Generators \ {categoryGuid} \ {toolName} \"

重定向路径:Registry.CurrentUser,"SOFTWARE \ Microsoft \ VisualStudio \ 10.0_Config \ Generators \ {categoryGuid} \ {toolName} \"

我没有"10.0_Config"在我的注册方法中的任何位置,都已确定将其添加到LocalMachine中,但是每次运行时,新密钥都会以某种方式最终在CurrentUser中的"10.0_Config"窗口中.文件夹.

请告知.

谢谢

解决方案

我应该补充一点,就是我也使用完全相同的注册表方法为VS2008使用添加了此工具,


Hi,

I'm trying to create a setup project for a "custom tool" (i.e. the things you can set in the properties window for a project file).  I want this to work with both VS2008 and VS2010, so I've referenced the 2008 SDK assembies and it seems to work fine on our developer machines (except for one little problem, which I'll describe later).

Now, say I want to deploy our solution.  I watched a video tutorial on deploying VS packages (http://msdn.microsoft.com/en-us/vstudio/cc627235.aspx) and he simply excludes all the SDK references from the setup project.  This works fine if you have the 2008 SDK installed, but I don't want users of our tool to have to download and install a 100mb package just to use our custom tool.  Is there a merge module or something I can include that will make sure all the dependencies install with our tool?

And the "little problem" I mentioned above: when I try to add the appropriate registry entries from a static method marked with [ComRegisterFunction] (using standard Microsoft.Win32 Registry methods), it redirects from "LocalMachine" to a different folder in "CurrentUser" instead, and VS can't find the tool where it goes.

Original path specified: Registry.LocalMachine, "SOFTWARE\Microsoft\VisualStudio\10.0\Generators\{categoryGuid}\{toolName}\"

Redirected path: Registry.CurrentUser, "SOFTWARE\Microsoft\VisualStudio\10.0_Config\Generators\{categoryGuid}\{toolName}\"

I don't have "10.0_Config" anywhere in my registration method and it is DEFINITELY being added to LocalMachine, yet everytime it runs, the new key somehow ends up in CurrentUser within a "10.0_Config" folder.

Please advise.

Thanks,

解决方案

I should add that I also add this tool for VS2008 usage, using the exact same registry method, to Registry.LocalMachine, "SOFTWARE\Microsoft\VisualStudio\9.0\Generators\{categoryGuid}\{toolName}\" and it works just fine - key ends up where I told it to go.


这篇关于Visual Studio自定义工具安装程序的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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