Menu

SaveFile outputs extra end-tokens

Neal
2006-10-11
2013-05-20
  • Neal

    Neal - 2006-10-11

    Im calling SaveFile() to output an XML structure.  When I have objects without sub-objects, the end of the XML gets extra finish tokens.  The behavior seems to be that I get an extra </INDEX> token at the end for every <ENTRY> token that has no sub-objects.   Does anyone have any idea what could cause this?

    Here is what it looks like:

    <?xml version="1.0" standalone="no" ?>
    <!DOCTYPE s1 SYSTEM "sbk:/style/dtd/document.dtd">
    <INDEX>
        <ENTRY NAME="a" PATH="C:\Program Files\Spectrasonics\SAGE\Peach\Patches" LIBRARY="nickname">
            <ATTR NAME="a" VALUE="1" SCORE="0" />
        </ENTRY>
        <ENTRY NAME="CC" PATH="C:\Program Files\Spectrasonics\SAGE\Peach\Patches" LIBRARY="nickname">
            <ATTR NAME="zz" VALUE="3" SCORE="0" />
        </ENTRY>
        <ENTRY NAME="Apple" PATH="C:\Program Files\Spectrasonics\SAGE\Peach\Patches" LIBRARY="nickname" />
        <ENTRY NAME="ant" PATH="C:\Program Files\Spectrasonics\SAGE\Peach\Patches" LIBRARY="nickname" />
        <ENTRY NAME="Appetizer CXX" PATH="C:\Program Files\Spectrasonics\SAGE\Peach\Patches" LIBRARY="nickname" />
    </INDEX>
    </INDEX>
    </INDEX>
    </INDEX>

     
    • Neal

      Neal - 2006-10-11

      The indendation of this XML file was lost when I pasted it here.   The indentation (produced by SaveFile()) is correct thru the entire file, and the first (correct) </INDEX> token is fully left justified.   The additional (incorrect) </INDEX> tokens are also fully left justified.

      I mention this in case it is a clue.

       

Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.