简体   繁体   English

具有用户输入值的Installshield修补XML文件更改

[英]Installshield Patching XML File Changes with User Input Values

I'm using InstallShield 2010 to create a patch of my product. 我正在使用InstallShield 2010创建产品补丁。 There are many changes so I am using the patch design view to create a MSP patch that differences my original product release MSI and the current MSI. 有很多更改,因此我使用补丁程序设计视图来创建一个MSP补丁程序,该补丁程序与我的原始产品版本MSI和当前的MSI不同。 My installer uses the XML file changes InstallShield feature to write XML file values during installation. 我的安装程序使用XML文件更改InstallShield功能在安装过​​程中写入XML文件值。 Some of the values written are collected via custom dialogs during install. 在安装过程中,某些写入的值是通过自定义对话框收集的。 My issue is that when applying the patch these values are NULL because there are no user dialogs shown during the MSP patch installation. 我的问题是,在应用补丁程序时,这些值均为NULL,因为在MSP补丁程序安装期间未显示任何用户对话框。 What happens is since the values are not populated from user input, the MSP will put blank values into the XML which essentially deletes the values that the user specified during the initial installation. 发生的情况是,由于未从用户输入中填充值,因此MSP会将空白值放入XML,这实际上删除了用户在初始安装过程中指定的值。 Can I add dialogs to the patch so I can re-collect the necessary values from the user during patch install? 是否可以在补丁程序中添加对话框,以便在补丁程序安装期间可以向用户重新收集必要的值?

One thing I was thinking was to write a boot strapper batch script and pass the property values via an msiexec.exe call in the manor of PROPERTY="VALUE", but I was hoping identify some alternatives. 我当时想到的一件事是编写引导打包程序批处理脚本,并通过PROPERTY =“ VALUE”的庄园中的msiexec.exe调用传递属性值,但我希望能找到一些替代方法。

Generally you should have searches read the current values into the properties. 通常,您应该通过搜索将当前值读入属性。 You might be able to do this with the XML System Search support in InstallShield, or you may have to write a custom action. 您可以通过InstallShield中的XML System Search支持来执行此操作,或者您可能必须编写自定义操作。 (The XML System Search support doesn't handle namespaces as well as the XML File Changes does). (XML系统搜索支持不像XML文件更改那样处理名称空间)。

Once you build this change into the Upgraded installer and patch, your patch should similarly run these searches before running the XML changes. 一旦将此更改构建到“升级的安装程序”和修补程序中,您的修补程序应在运行XML更改之前类似地运行这些搜索。 In full UI maintenance scenarios this may have the benefit of showing up as default values already populated, but make sure of that too. 在完整的UI维护方案中,这样做的好处是可以显示为已填充的默认值,但也请确保这一点。

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

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