I'm trying to write the WiX v3 code to modify an XML file in my
installation.  The goal is to add elements, but instead an existing element
gets changed.  I stripped this problem down to the bare minimum and zipped
it up to be buildable (.wxs, .bat, 2 very small source files):

http://mindcapers.com/samples/XmlConfigProblem.zip

I think it might be a WiXUtilExtension bug, but I'm hoping its just a
mistake on my part.  Here is the WiX source if you want to look before
downloading:

<?xml version='1.0'?>
<Wix xmlns='http://schemas.microsoft.com/wix/2006/wi'
     xmlns:util='http://schemas.microsoft.com/wix/UtilExtension'>     

    <Product Id='{EC411C25-89B7-4586-9BDA-48DA76A61FD9}' 
        Name='XmlConfig Problem' 
        Language='1033'
        Version='1.0.0' 
        Manufacturer='MindCapers' 
        UpgradeCode='{E8254079-0516-4b76-9ECB-4F88EA19D861}'>
        <Package Description='XmlConfig Problem'
            Comments='XmlConfig Problem'
            Manufacturer='MindCapers' InstallerVersion='200'
Compressed='yes' />
 
        <Media Id='1' Cabinet='XmlConfigProblem.cab' EmbedCab='yes' />

        <Directory Id='TARGETDIR' Name='SourceDir'>
            <Directory Id='ProgramFilesFolder' Name='PFiles'>
                <Directory Id='INSTALLDIR' Name='MindCapers'>  
                    <Component Id='SOME_XML_FILE'
Guid='{6CB5D69F-427D-429d-B7C0-3D0E4412A8E9}'>
                        <File Id='SOME_XML_FILE' Name='plugin.xml'
Source='C:\XmlConfigProblem\plugin.xml'/>
                    </Component>
                    <Component Id='SOME_XML_CONFIG'
Guid='{EB73DB52-D140-4076-B7E8-A8A165E300BE}'>
                        <File Id='SOME_TOC_FILE' Name='SomeTOC.xml'
Source='C:\XmlConfigProblem\SomeTOC.xml'/>
                        <util:XmlConfig 
                            Id='ADD_SOME_TOC'
                            Sequence='26001'
                            Action='create' 
                            On='install'
                            Name='toc' 
                            Node='element'
                            ElementPath='/plugin/extension'
                            File='[INSTALLDIR]plugin.xml'
 
VerifyPath='/plugin/extension/[EMAIL PROTECTED]"SomeTOC.xml"[\]]' />

        
                        <util:XmlConfig 
                            Id='SET_SOME_TOC_FILE'
                            Sequence='26002'
                            Action='create' 
                            On='install'
                            Name='file' 
                            Node='value'
                            ElementPath='/plugin/extension/toc'
                            File='[INSTALLDIR]plugin.xml'
                            Value='SomeTOC.xml'
 
VerifyPath='/plugin/extension/[EMAIL PROTECTED]"SomeTOC.xml"[\]]' />

                    </Component>
                </Directory>
            </Directory>
        </Directory>      

        <Feature Id='Express' 
            Title='XmlConfigProblem' 
            Description='XmlConfigProblem' 
            Display='expand'
            Level='1'>      
            <ComponentRef Id='SOME_XML_FILE' />
            <ComponentRef Id='SOME_XML_CONFIG' />
        </Feature>            
    </Product>
                    
</Wix>
Julie Campbell
[EMAIL PROTECTED]



_____________________________________________________________________________
Scanned by IBM Email Security Management Services powered by MessageLabs. For 
more information please visit http://www.ers.ibm.com
_____________________________________________________________________________

-------------------------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >>  http://get.splunk.com/
_______________________________________________
WiX-users mailing list
WiX-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wix-users

Reply via email to