
July 17th, 2003, 05:52 AM
|
 |
Contributing User
|
|
Join Date: Jul 2003
Posts: 206
Time spent in forums: 19 h 29 m 24 sec
Reputation Power: 6
|
|
|
compare two files
I want to compare the two files and show the differences.
File1
Code:
<Forms>
<Form name=1>
</Form>
<Form name=2>
</Form>
<Form name=3>
</Form>
<Form name=4>
</Form>
</Forms>
File2
Code:
<Forms>
<Form name=1>
</Form>
<Form name=3>
</Form>
<Form name=4>
</Form>
<Form name=2>
</Form>
<Form name=5>
</Form>
</Forms>
I tried to iterate over all nodes in file1 and then for each node in file1 I search for the node with the same attribute in file2.
Now the problem is that all nodes that are just in file2 are not found. So I guess I have to handle all nodes in file2 too.
Has anyone suggestions how to do it in an easy way?
Thanks in advance
|