添加Windows特性从C#特性、Windows

2023-09-06 05:48:31 作者:精神食粮

作为一个安装包我工作的一部分,我需要添加IIS的功能上的Win7和Win Server 2008中。 有什么办法增加新的Windows功能从code?

As part of an installation package I'm working on, I need to add the IIS feature on Win7 and Win Server 2008. Is there any way of adding new windows features from code?

推荐答案

您可以通过调用的 PKGMGR (一个命令行实用程序安装功能和包)。

You can do this by calling pkgmgr (a command line utility for installing features and packages).

还有就是如何做到这一点的MSMQ在这里的一个例子:

There is an example of how to do this for MSMQ here:

使用安装MSMQ C#