有时候我们需要在程序中执行另一个程序的安装,这就需要我们去自定义 msi 安装包的执行过程。

需求

比如我要做一个安装管理程序,可以根据用户的选择安装不同的子产品。当用户选择了三个产品时,如果分别显示这三个产品的安装交互 UI 显然是不恰当的。我们期望用一个统一的自定义 UI 去取代每个产品各自的 UI。

实现思路

平时使用 msiexec.exe 习惯了,所以最直接的想法就是在一个子进程中执行:

msiexec.exe /qn

这样固然是能够完成任务,但是不是太简陋了? 安装开始后我们想取消这次安装怎么办? 或者我们还想要拿到一些安装进度的信息。

其实可以通过调用三个 windows API 轻松搞定这个事儿!下面的 C# demo 用一个自定义 Form 来指示多个 MSI 文件的安装过程。Form 上放的是一个滚动条,并且配合一个不断更新的 label。先看看 demo 长什么样子。
下面是安装过程中的 UI:

aaarticlea/png;base64,iVBORw0KGgoAAAANSUhEUgAAAkAAAADOCAIAAABZ3SrgAAAgAElEQVR4nO3dd1hUB77/cXbT7t393fvbezd79/fs3b2b7Koxe43SRKUoCIKgIgiiiPQ6ZwBj70rUrBpLYomJMSp2KVJFVFDq9EaxoWBUYPqZ06YywPn9MYCAaHQVmFm/r+fz+IwDwWHg4Z05TLErOxaMspIJHoJzGTAYDAaDWUbVMx//GFPrF8gJChqtsQODuAuClFeTSFFPpAgeoq5NqDwdoVLK7CBgMBgMBnt2Vh4whawNAgaDwWCwIWblAZO2PYaAwWAw2D//CB7DIGIOPTFTJ2Q++59YdcBORbS3Pvr5gJHcpJcZwU0e9a8QDAaDwZ4dwWOgrJTmq3FD7n5p3OPyBII3+L96nYCx581jBQSwA5/+t+y5cwedM+wBw7iIirNSwVltmZKzSsVZqeSu65uKu07FW6/irlVzluHclFH/OsFgMBhs0EyS1Lq86AkTPv1k3Cfjx4//tN/Gjx//Px+NTVjs3lGXOqhh/3DA2IGBwuhocWIiNySEPXcuJziYFRDAX7JEnJzMX7z4lRr2jweM5CbKOWurK8vYVZc5VcWcqmJ21ZXqyuu15VnV189Wl52rvn6u6tq5qmvnK8qv1NWcpbgJo/51gv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2AvmqDIAiz2cw+xXXx4kU7OzvroUKSJFtaWoqKirZu3RoREeHk5PTHP/7x+++/37x5865du7799tstW7Zs3br1woULDMPs27fv008/PX78uJub24IFCxiG2blzp5eXF8MwX3/9tZ+fX0xMzMGDB9nDhgzDFBQUFBUVbdy4ce3atSUlJfn5+QzDXL9+XSwWs527cOFCcnJyz44mJSWxhwfPnz//7rvv7tu3z/ohV1fXM2fOsKfNZjOOHAIADLwBrVdra6tUKv3qq68Yhrl48WLPx16dnZ0Gg4FtG8Mwly5dGjVqFHtaJpNZn9liDy0ePHjw3XffDQwMtLOz8/b2Zhjmq6++8vDwYBjmyy+/nDdvnkwmmzdv3oEDB9ra2q5cueLn57d06dK33nrr97///dKlS/38/C5evNizVQsWLFi9evWTRyl37tzJ4XDGjBnz3XffMQyze/fuefPm/cd//MeHH37o6emZmpqKw4YAAINiQOvFPuT63//9X4Zh4uPj//u//9vd3d3FxcXFxWXjxo2tra0URbW1tWVnZ69YseL69etsqw4fPjx+/Hg2XQRBsI+9Pv744z179syaNWvRokVsvZYvX37jxg0/P7/09HSGYbKzsy9dusQwDIfDGTFiRGRk5KlTp06dOhUZGTly5Mi1a9dGR0e7uLg4Ozv7+Pj86U9/evvttz09Pb28vBYuXOjs7Ozi4pKQkBATE1NdXe3i4sIWNzExMSIi4rvvvtuzZ8/XX3+Nw4YAAINlQOvV2dkZExMzYsQIhmGuXr36zjvvRERE7NixY/v27VFRUexROIZhIiMjR48ezTBMWlqau7v78OHDf//737u7u+/YsaO9vZ1hmB07drAHDI8cOeLs7MwwzKpVq4KDg3fv3j1z5kyGYQwGg/Xx04YNGz788MOAgAAfHx8fH5+AgICPPvpo69atUqn0m2+++eGHH95///0xY8YcPXp07969f/3rXydMmPCvf/1r+/btOTk51mfjqqqqGIY5duxYQUFBzwdnOHIIADAoBq1eTz1yyDBMcXHxZ599Nnv2bPb5qr1797q7u3/wwQd79+69dOmSxWJhGObkyZN/+MMf3N3dP/744yVLljAMk5+fv3r16tDQ0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3/H3GBqVStbEAMAAAAAElFTkSuQmCC" alt="" />

主要接口介绍

我们先来了解一下主要用到的几个 win32 API。

首先是 MsiSetInternalUI 方法:

[DllImport("msi.dll", CharSet = CharSet.Auto)]
internal static extern int MsiSetInternalUI(int dwUILevel, IntPtr phWnd);

在调用 msiexec.exe 时,我们通过指定 /q 参数让安装过程显示不同的 UI。如果不显示UI的话就要使用参数 /qn 。MsiSetInternalUI 方法就是干这个事儿的。通过下面的调用就可以去掉 msi 中自带的 UI:

NativeMethods.MsiSetInternalUI(, IntPtr.Zero)

接下来是 MsiSetExternalUI 方法:

[DllImport("msi.dll", CharSet = CharSet.Auto)]
internal static extern MsiInstallUIHandler MsiSetExternalUI([MarshalAs(UnmanagedType.FunctionPtr)] MsiInstallUIHandler puiHandler, NativeMethods.InstallLogMode dwMessageFilter, IntPtr pvContext);

MsiSetExternalUI 函数允许指定一个用户定义的外部 UI handler 用来处理安装过程中产生的消息。这个外部的 UI handler 会在内部的 UI handler 被调用前调用。 如果在外部的 UI handler 中返回非 0 的值,就说明这个消息已经被处理。
这个外部的 UI handler 就是 MsiSetExternalUI 方法的第一个参数,我们通过实现这个 handler 来处理自己感兴趣的消息, 比如当安装进度变化后去更新进度条。或者通过它传递我们的消息给 msi,比如说告诉 msi,停止安装,执行 cancel 操作。使用这个方法需要注意的是,当你完成安装后一定要把原来的 handler 设回去。否则以后执行 msi 安装包可能会出问题。
MSDN 上有一个 MsiInstallUIHandler 的 demo,感兴趣的同学可以去看看。

下面是 MsiInstallProduct 方法:

[DllImport("msi.dll", CharSet = CharSet.Auto)]
internal static extern uint MsiInstallProduct([MarshalAs(UnmanagedType.LPWStr)] string szPackagePath, [MarshalAs(UnmanagedType.LPWStr)] string szCommandLine);

正如其名,这个是真正干活儿的方法。

实在忍不住要介绍第四个方法,虽然它对实现当前的功能来说是可选的,但对一个产品来说,它却是用来救命的。

[DllImport("msi.dll", CharSet = CharSet.Auto)]
internal static extern uint MsiEnableLog(GcMsiUtil.NativeMethods.InstallLogMode dwLogMode, [MarshalAs(UnmanagedType.LPWStr)] string szLogFile, uint dwLogAttributes);

这个方法会把安装 log 保存到你传递给它的文件路径。有了它生活就会 happy 很多,很多… 否则当用户告诉你安装失败时,你一定会抓狂的。

主要代码

好了,下面是 MyInstaller demo 的主要代码:

InstallProcessForm.cs
public partial class InstallProcessForm : Form
{
private MyInstaller _installer = null;
private BackgroundWorker _installerBGWorker = new BackgroundWorker();
internal InstallProcessForm()
{
InitializeComponent(); _installer = new MyInstaller(); _installerBGWorker.WorkerReportsProgress = true;
_installerBGWorker.WorkerSupportsCancellation = true; _installerBGWorker.DoWork += _installerBGWorker_DoWork;
_installerBGWorker.RunWorkerCompleted += _installerBGWorker_RunWorkerCompleted;
_installerBGWorker.ProgressChanged += _installerBGWorker_ProgressChanged; this.Shown += InstallProcessForm_Shown;
} private void InstallProcessForm_Shown(object sender, EventArgs e)
{
// 当窗口打开后就开始后台的安装
_installerBGWorker.RunWorkerAsync();
} private void _installerBGWorker_ProgressChanged(object sender, ProgressChangedEventArgs e)
{
// 消息通过 e.UserState 传回,并通过label显示在窗口上
string message = e.UserState.ToString();
this.label1.Text = message;
if (message == "正在取消安装 ...")
{
this.CancelButton.Enabled = false;
}
} private void _installerBGWorker_RunWorkerCompleted(object sender, RunWorkerCompletedEventArgs e)
{
// 安装过程结束
} private void _installerBGWorker_DoWork(object sender, DoWorkEventArgs e)
{
BackgroundWorker bgWorker = sender as BackgroundWorker; // 开始执行安装方法
_installer = new MyInstaller();
string msiFilePath = "xxx.msi"; // msi file path
_installer.Install(bgWorker, msiFilePath);
} private void CancelButton_Click(object sender, EventArgs e)
{
_installer.Canceled = true;
_installerBGWorker.CancelAsync();
}
}
MyInstaller.cs
internal class MyInstaller
{
private BackgroundWorker _bgWorker = null; public bool Canceled { get; set; } public void Install(BackgroundWorker bgWorker, string msiFileName)
{
_bgWorker = bgWorker; NativeMethods.MyMsiInstallUIHandler oldHandler = null;
try
{
string logPath = "test.log";
NativeMethods.MsiEnableLog(NativeMethods.LogMode.Verbose, logPath, 0u);
NativeMethods.MsiSetInternalUI(, IntPtr.Zero); oldHandler = NativeMethods.MsiSetExternalUI(new NativeMethods.MyMsiInstallUIHandler(MsiProgressHandler),
NativeMethods.LogMode.ExternalUI,
IntPtr.Zero);
string param = "ACTION=INSTALL";
_bgWorker.ReportProgress(, "正在安装 xxx ...");
NativeMethods.MsiInstallProduct(msiFileName, param);
}
catch(Exception e)
{
// todo
}
finally
{
// 一定要把默认的handler设回去。
if(oldHandler != null)
{
NativeMethods.MsiSetExternalUI(oldHandler, NativeMethods.LogMode.None, IntPtr.Zero);
}
}
} //最重要的就是这个方法了,这里仅演示了如何cancel一个安装,更多详情请参考MSDN文档
private int MsiProgressHandler(IntPtr context, int messageType, string message)
{
if (this.Canceled)
{
if (_bgWorker != null)
{
_bgWorker.ReportProgress(, "正在取消安装 ...");
}
// 这个返回值会告诉msi, cancel当前的安装
return ;
}
return ;
}
} internal static class NativeMethods
{
[DllImport("msi.dll", CharSet = CharSet.Auto)]
internal static extern int MsiSetInternalUI(int dwUILevel, IntPtr phWnd); [DllImport("msi.dll", CharSet = CharSet.Auto)]
internal static extern MyMsiInstallUIHandler MsiSetExternalUI([MarshalAs(UnmanagedType.FunctionPtr)] MyMsiInstallUIHandler puiHandler, NativeMethods.LogMode dwMessageFilter, IntPtr pvContext); [DllImport("msi.dll", CharSet = CharSet.Auto)]
internal static extern uint MsiInstallProduct([MarshalAs(UnmanagedType.LPWStr)] string szPackagePath, [MarshalAs(UnmanagedType.LPWStr)] string szCommandLine); [DllImport("msi.dll", CharSet = CharSet.Auto)]
internal static extern uint MsiEnableLog(NativeMethods.LogMode dwLogMode, [MarshalAs(UnmanagedType.LPWStr)] string szLogFile, uint dwLogAttributes); internal delegate int MyMsiInstallUIHandler(IntPtr context, int messageType, [MarshalAs(UnmanagedType.LPWStr)] string message); [Flags]
internal enum LogMode : uint
{
None = 0u,
Verbose = 4096u,
ExternalUI = 20239u
}
}

简单说明一下,用户定义的 UI 运行在主线程中,使用 BackgroundWorker 执行安装任务。在安装进行的过程中可以把 cancel 信息传递给 MsiProgressHandler,当MsiProgressHandler 检测到 cancel 信息后通过返回值告诉 msi 的执行引擎,执行 cancel 操作(msi的安装过程是相当严谨的,可不能简单的杀掉安装进程了事!)。
这样,一个支持 cancel 的自定义 UI 的安装控制程序就 OK了(demo哈)。如果要安装多个 msi 只需在 Install 方法中循环就可以了。

总结

通过调用几个 windows API,我们可以实现对 msi 安装过程的控制。这比调用 msiexec.exe 更灵活,也为程序日后添加新的功能打下了基础。

在 C# 中执行 msi 安装的更多相关文章

  1. [转]MSI安装程序中的文件替换

    原文链接:http://teach.hanzify.org/article/652-1233562028.html 前言 最近有汉化朋友问起如何不重新制作MSI文件,而直接用汉化好的文件替换MSI安装 ...

  2. 在Win10中,在安装msi安装包的时候常常会出现代码为2502、2503的错误。

    前言:在Win10中,在安装msi安装包的时候常常会出现代码为2502.2503的错误.其实这种错误是由于安装权限不足造成的,可以这种msi的安装包不像其他exe的安装程序,在安装包上点击“右键”之后 ...

  3. pyv8的安装和使用:python中执行js代码

    pyv8 的作用是在python中执行js代码,然后可以使用js里的变量等内容.python取得javascript里面的值.javascript取得python里面的值.python和javascr ...

  4. Vbox中Ubuntu的安装和共享文件夹设置

    1. 选择版本 1.1 Ubuntu桌面版与服务器版的区别 桌面版与服务器版,只要发布版本号一致,这两者从核心来说也就是相同的,唯一的差别在于它们的预期用途.桌面版面向个人电脑使用者,可以进行文字处理 ...

  5. Windows 10 安装ElasticSearch(2)- MSI安装ElasticSearch和安装Kibana

    翻阅上篇文章:Windows 10 安装 ElasticSearch 上次写的是下载Zip包安装的,在下载页面 发现有 MSI (BETA) 的下载可选项.了解之后发现MSI安装也值得尝试. MSI安 ...

  6. mac中使用brew安装软件,下载太慢怎么办?

    mac中使用brew安装软件,下载太慢怎么办? 本文所说的软件是指较大的软件,如果软件较小,例如软件只有几M,那么使用此方法后,提升会非常小. 了解brew原理: 1: 从网络下载安装包 2: 执行一 ...

  7. [linux]执行pip安装的程序:command not found

    执行pip安装的程序:command not found 问题描述: 我有一台阿里云服务器,上面装的是centos系统,我用pip安装好vituralenv,都没办法直接启动.同样 我今天在部署我的t ...

  8. Ubuntu 中软件的安装、卸载以及查看的方法总结

    Ubuntu 中软件的安装.卸载以及查看的方法总结 博客分类: Linux UbuntuDebian配置管理CacheF#  说明:由于图形化界面方法(如Add/Remove... 和Synaptic ...

  9. 黄聪:WebBrowser执行和安装jQuery脚本(IEBrowse)

    上一文章说明了如何让 js 脚本访问 .NET 中的类, 这次希望给大家说明一下在任意页面中安装 jQuery 脚本, 并操作页面上的元素. 其实在第一篇关于 IEBrowser 的文章当中, 已经有 ...

随机推荐

  1. #IrrlichtEngine# Example1 HelloWorld

    配置IDE环境来使用irrlicht引擎: (VS2012下)菜单栏项目 -> 项目属性窗口下 C/C++ -> 常规 -> 附加包含目录中添加irrlicnt引擎文件目录下incl ...

  2. ASP.NET Core 1.0中的管道-中间件模式

    ASP.NET Core 1.0借鉴了Katana项目的管道设计(Pipeline).日志记录.用户认证.MVC等模块都以中间件(Middleware)的方式注册在管道中.显而易见这样的设计非常松耦合 ...

  3. 【译】ASP.NET应用程序和页面生命周期

    为何翻译此文 一.此文是Code Project社区2010年4月ASP.NET板块的最佳文章,说明了此文的份量: 二.锻炼自己的英文技术文章翻译能力,提高英文技术文档阅读能力: 三.了解掌握ASP. ...

  4. 开源一个练手小App, PrintableCheckList

    A small but powerful App, only focus on one thing, make you easy to print out your checklist. It is ...

  5. Atitit wsdl的原理attilax总结

    Atitit wsdl的原理attilax总结 1.1. 在 W3C 的 WSDL 发展史1 1.2. 获取wsdl,可能需要url后面加wsdl,也可能直接url1 1.3. Wsdl的作用2 1. ...

  6. WCF学习之旅——第一个WCF示例(二)

    第四步:通过自我寄宿的方式寄宿服务 WCF服务需要依存一个运行着的进程(宿主),服务寄宿就是为服务指定一个宿主的过程.WCF是一个基于消息的通信框架,采用基于终结点(Endpoint)的通信手段. 终 ...

  7. jquery中on/delegate的原理

    jquery中on/delegate的原理 早期版本中叫delegate, 后来有过live函数,再后来统一用on.下面的方法等效: // jQuery 1.3 $(selector).(events ...

  8. PLSQL使用技巧

    PL/SQL Developer记住登陆密码    在使用PL/SQL Developer时,为了工作方便希望PL/SQL Developer记住登录Oracle的用户名和密码: 设置方法:PL/SQ ...

  9. java.io中的System.in、 System.out和System.err

    System.in, System.out, System.err这3个流同样是常见的数据来源和数据流目的地.使用最多的可能是在控制台程序里利用System.out将输出打印到控制台上. JVM启动的 ...

  10. C# 获取当前月第一天和最后一天 计算两个日期差多少天

    获取当前月的第一天和最后一天 DateTime now = DateTime.Now; DateTime firstDay = ); DateTime lastDay = firstDay.AddMo ...