0

我有两个运行两个 EXE 文件的自定义操作。但是它们同时被提取,并且在安装过程中进程相互阻塞。我如何安排他们一个接一个?

<CustomAction Id="StartAppOnExit1"
              FileKey="UMIEXE"
              ExeCommand=""
              Execute="deferred"
              Return="asyncNoWait"
              Impersonate="no" />

<InstallExecuteSequence>
    <Custom Action="StartAppOnExit1"
            Before="InstallFinalize">$UMIEXE=3</Custom>
</InstallExecuteSequence>

<CustomAction Id="StartAppOnExit2"
              FileKey="Python"
              ExeCommand=""
              Execute="commit"
              Return="check"
              Impersonate="no" />

<InstallExecuteSequence>
    <Custom Action ="StartAppOnExit2"
            After="StartAppOnExit1" >$Python=3</Custom>
</InstallExecuteSequence>

这是我的代码,但我似乎对您所说的内容有误。

4

1 回答 1

1

在 product.wxs 中依次对它们进行排序,并在自定义操作中检查以验证 exe 是否已执行并仅将进程保留在那里

<Custom Action="FirstCustomAction" After="InstallFinalize">NOT INSTALLED AND NOT REMOVE</Custom>
<Custom Action="SecondCustomAction" After="FirstCustomAction">NOT INSTALLED AND NOT REMOVE</Custom>

WaitForExit()在流程调用中的 CustomAction 中。

于 2012-11-15T13:57:57.953 回答