login about faq

I have a WCF web service that I use other (paid) Chilkat components in and have just started leveraging the free XML class.

In this service, an XML document is created during the scanning of 3 distinct systems, all of which have some unique attributes as well as several common attributes.

The basic layout of the document is:


However, in each node, there could either be a child with a value, or a parent who has children of its own:


Where the interesting behavior comes into play and something out of my control, depending on the state of a given VM, some values may not be populated. For example, if a VM is turned off, certain properties cannot be retrieved.

However, other attributes that are retrieved may have been updated since the last retrieval and I want to persist those changes.

To do this, I need to treat the XML I already have stored as the "master" document and merge the contents of the newly retrieved content and anywhere there is a match, overwrite and anything new, append.

I went through the example apps hoping this was a simple process that was integrated into the library but I didn't see anything. I could write it from scratch but if anyone has an example lying around it would be greatly appreciated.



asked Mar 13 '13 at 12:12

JD%20BuckSavage's gravatar image

JD BuckSavage

Anyone? :)

(Mar 14 '13 at 15:45) JD BuckSavage

Have you considered leveraging LinqToXML ? 3rd party components like Chilkat specialize in getting you the information, and sometimes go the extra mile with features that help with common tasks, but when you delve into areas like the one you describe (XML manipulation), you are getting into the specialized realms of programming. Personally, I would use LinqToXML as a first option if your platform (.net 3.5 or higher) will support it. Google it and see if it will work for you.


answered Apr 03 '13 at 22:55

SirJamsalot's gravatar image


edited Apr 03 '13 at 22:56

Your answer
toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here



Answers and Comments

Markdown Basics

  • *italic* or __italic__
  • **bold** or __bold__
  • link:[text](http://url.com/ "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported



Asked: Mar 13 '13 at 12:12

Seen: 1,635 times

Last updated: Apr 03 '13 at 22:56

powered by OSQA