Visual Studio安装项目自定义对话框

时间:2022-05-25 10:20:51

I have created a custom dialog for Visual Studio Setup Project using the steps described here

我使用此处描述的步骤为Visual Studio安装项目创建了自定义对话框

Now I have a combobox in one of my dialogs. I want to populate the combobox with a list of all SQL Server instances running on the local network. It's trivial to get the server list ... but I'm completely lost on how to make them display in the combobox. I would appreciate your help and some code might also be nice as I'm beginner :).

现在我在一个对话框中有一个组合框。我想用一个在本地网络上运行的所有SQL Server实例的列表填充组合框。获取服务器列表是微不足道的...但我完全迷失了如何让它们在组合框中显示。我很感激你的帮助,一些代码可能也很好,因为我是初学者:)。

2 个解决方案

#1


12  

I've always found the custom dialogs in visual studio setup projects to be woefully limited and barely functional.

我总是发现Visual Studio安装项目中的自定义对话框非常有限,几乎没有功能。

By contrast, I normally create custom actions that display winforms gui's for any remotely difficult tasks during setup. Works really well and you can do just about anything you want by creating a custom action and passing a few parameters across.

相比之下,我通常会创建自定义操作,在安装过程中为任何远程困难任务显示winforms gui。工作得非常好,您可以通过创建自定义操作并传递一些参数来完成您想要的任何操作。

In the dayjob we built a collection of common custom actions for tasks like application config and database creation / script execution to get around custom dialog limitations.

在dayjob中,我们为应用程序配置和数据库创建/脚本执行等任务构建了一组常用自定义操作,以绕过自定义对话框限制。

#2


1  

I guess you'll have to go beyond the out-of-the-box setup and deployment package and try a third party app.

我想你必须超越开箱即用的设置和部署包,并尝试第三方应用程序。

You may want to look at:

你可能想看看:

Both are free; they might give you the customization that you need.

两者都是免费的;他们可能会为您提供所需的自定义。

#1


12  

I've always found the custom dialogs in visual studio setup projects to be woefully limited and barely functional.

我总是发现Visual Studio安装项目中的自定义对话框非常有限,几乎没有功能。

By contrast, I normally create custom actions that display winforms gui's for any remotely difficult tasks during setup. Works really well and you can do just about anything you want by creating a custom action and passing a few parameters across.

相比之下,我通常会创建自定义操作,在安装过程中为任何远程困难任务显示winforms gui。工作得非常好,您可以通过创建自定义操作并传递一些参数来完成您想要的任何操作。

In the dayjob we built a collection of common custom actions for tasks like application config and database creation / script execution to get around custom dialog limitations.

在dayjob中,我们为应用程序配置和数据库创建/脚本执行等任务构建了一组常用自定义操作,以绕过自定义对话框限制。

#2


1  

I guess you'll have to go beyond the out-of-the-box setup and deployment package and try a third party app.

我想你必须超越开箱即用的设置和部署包,并尝试第三方应用程序。

You may want to look at:

你可能想看看:

Both are free; they might give you the customization that you need.

两者都是免费的;他们可能会为您提供所需的自定义。