开发者

MSI - How to know when a particular MSI is running

Is there a simply way to know when an msi is running? (either in silent or no silent mode.) Maybe using and MSI API? Reading from somewhere?...

I need this in order to avoid launching a pro开发者_运维问答gram coded in C++.

Thanks for your help.


There isn't any API for detecting running installers. Also, an MSI installation has two sequences:

  • the installation UI -> InstallUISequence
  • the actual installation process -> InstallExecuteSequence

InstallUISequence uses a process which runs under the current user account. InstallExecuteSequence uses a process which is a child of the Windows Installer service.

So there's not an easy way for detecting a running installation. The only solution I can think of is enumerating all open windows and trying to find an installation dialog by name.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜