Add, modify and xml file using C++ (DOM)
Dear All,
Using C++ (DOM), I have designed a class where it can create an xml file with a certain structure. Now I have another class that loads this xml file, but currently stuck to add or modify child nodes to this xml file without the need to create the structure all over again.
Please help, I am stuck for the last 3 days :(
Many thnx
Re: Add, modify and xml file using C++ (DOM)
The obvious way to do this is to derive your new class for the original class (use the 'is-a' relationship). That way the structure can be re-used.
Your instance of the new class can then also be used to create the data. Just remember to reset the data before loading from a saved file.
Re: Add, modify and xml file using C++ (DOM)
I don't know that whether its suits ur requirements, but have a look at A Simple DOM-Based XML Manager Class