简体   繁体   English

尚未解析的CustomAction参考:WiX中的清理

[英]Unresolved reference to CustomAction:Cleanup in WiX

When processing an MSI file from Installshield with dark.exe it generates a file with multiple instances of the error when built from Visual Studio 2013: 使用dark.exe从Installshield处理MSI文件时,从Visual Studio 2013生成时,它会生成一个包含多个错误实例的文件:

Unresolved reference to symbol 'CustomAction:CleanUp'

Part of the wxs file is: 部分wxs文件是:

          <Dialog Id="SetupCompleteSuccess" X="50" Y="50" Width="374" Height="266" Title="[ProductName] - InstallShield Wizard" NoMinimize="yes">
            <Control Id="OK" Type="PushButton" X="230" Y="243" Width="66" Height="17" Text="&amp;Finish" TabSkip="no" Default="yes" Cancel="yes">
                <Publish Event="DoAction" Value="CleanUp">ISSCRIPTRUNNING="1"</Publish>
                <Publish Event="DoAction" Value="LaunchProgramFileFromSetupCompleteSuccess">LAUNCHPROGRAM And PROGRAMFILETOLAUNCHATEND &lt;&gt; "" And NOT Installed</Publish>
                <Publish Event="EndDialog" Value="Exit">1</Publish>
                <Publish Event="DoAction" Value="ShowMsiLog">MsiLogFileLocation And (ISSHOWMSILOG="1") And NOT ISENABLEDWUSFINISHDIALOG</Publish>
            </Control>

Looking at the MSI file with ORCA, in table CustomAction contains an entry for LaunchProgramFileFromSetupCompleteSuccess (which does not throw an error) and no entry for Cleanup, so dark.exe is behaving consistently as it creates a set of CustomActions as follows: 使用ORCA查看MSI文件,在表CustomAction中包含LaunchProgramFileFromSetupCompleteSuccess的条目(不会抛出错误),并且没有清除条目,因此dark.exe的行为一致,因为它创建了一组CustomActions,如下所示:

       <CustomAction Id="ISPreventDowngrade" Error="[IS_PREVENT_DOWNGRADE_EXIT]" />
    <CustomAction Id="ISRunSetupTypeAddLocalEvent" BinaryKey="ISExpHlp.dll" DllEntry="RunSetupTypeAddLocalEvent" />
    <CustomAction Id="ISSelfRegisterCosting" BinaryKey="ISSELFREG.DLL" DllEntry="ISSelfRegisterCosting" />
    <CustomAction Id="ISSelfRegisterFiles" BinaryKey="ISSELFREG.DLL" DllEntry="ISSelfRegisterFiles" Execute="deferred" Impersonate="no" />
    <CustomAction Id="ISSelfRegisterFinalize" BinaryKey="ISSELFREG.DLL" DllEntry="ISSelfRegisterFinalize" />
    <CustomAction Id="ISUnSelfRegisterFiles" BinaryKey="ISSELFREG.DLL" DllEntry="ISUnSelfRegisterFiles" Execute="deferred" Impersonate="no" />
    <CustomAction Id="SetARPINSTALLLOCATION" Property="ARPINSTALLLOCATION" Value="[INSTALLDIR]" />
    <CustomAction Id="SetAllUsersProfileNT" Property="ALLUSERSPROFILE" Value="[%SystemRoot]\Profiles\All Users" />
    <CustomAction Id="setAllUsersProfile2K" Property="ALLUSERSPROFILE" Value="[%ALLUSERSPROFILE]" />
    <CustomAction Id="setUserProfileNT" Property="USERPROFILE" Value="[%USERPROFILE]" />
    <CustomAction Id="ShowMsiLog" Directory="SystemFolder" ExeCommand="[SystemFolder]notepad.exe &quot;[MsiLogFileLocation]&quot;" Return="asyncNoWait" />
    <CustomAction Id="LaunchProgramFileFromSetupCompleteSuccess" BinaryKey="NewBinary19" DllEntry="LaunchProgram" />
    <CustomAction Id="ISPrint" BinaryKey="SetAllUsers.dll" DllEntry="PrintScrollableText" />

How should I deal with this problem? 我该如何处理这个问题?

Find in which dll ' Cleanup ' custom action is present and add a reference 找到哪个dll' 清理 '自定义操作存在并添加引用

<Binary Id="CleanupBinary" SourceFile="Your location of the CleanUp Dll" />
<CustomAction Id="CleanUp" BinaryKey="CleanupBinary" DllEntry="Your cleanup custom action name" />

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM