KnowledgeHub
Questions
Tags
Users
Search
Alex Rivera
|
Logout
Edit Question
Title
Body
I am trying to write a simple algorithm to read two XML files with the exact same nodes and structure but not necessarily the same data inside the child nodes and not the same order. How could I create a simple implementation for creating a third, temporary XML being the differential between the two first ones, using Microsoft's XML Diff .DLL ? XML Diff on MSDN: XML Diff and Patch Tool XML Diff and Patch GUI Tool sample XML code of the two different XML files to compare: <?xml version="1.0" encoding="utf-8" ?> <Stats Date="2011-01-01"> <Player Rank="1"> <Name>Sidney Crosby</Name> <Team>PIT</Team> <Pos>C</Pos> <GP>39</GP> <G>32</G> <A>33</A> <PlusMinus>20</PlusMinus> <PIM>29</PIM> </Player> </Stats> <?xml version="1.0" encoding="utf-8" ?> <Stats Date="2011-01-10"> <Player Rank="1"> <Name>Sidney Crosby</Name> <Team>PIT</Team> <Pos>C</Pos> <GP>42</GP> <G>35</G> <A>34</A> <PlusMinus>22</PlusMinus> <PIM>30</PIM> </Player> </Stats> Result wanted (difference between the two) <?xml version="1.0" encoding="utf-8" ?> <Stats Date="2011-01-10"> <Player Rank="1"> <Name>Sidney Crosby</Name> <Team>PIT</Team> <Pos>C</Pos> <GP>3</GP> <G>3</G> <A>1</A> <PlusMinus>2</PlusMinus> <PIM>1</PIM> </Player> </Stats> In this case, I would probably use XSL
Tags (comma-separated)
Save Edits
Cancel