Re: Read XML File



<ssamuel@xxxxxxxxx> schreef in bericht
news:1161644074.407703.277010@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
Gerrit,

1. Create a XmlDocument.
2. Use LoadXml() on your instance to load your XML. You can also use
Load(), depending on where your XML is coming from.
3. SelectNodes() with an XPath expression (try Relations/Person) to get
back an XmlNodeList.
4. Parse each member node into whatever you want in your list and add
it to your ArrayList.

You may find it cleaner to create IXmlSerializable Person and Relations
objects that deserialize themselves from an XmlReader.

Stephan

Thanks for your answer, but..

I have read more of this kind of explanation, but my English is not so good
and I am new in C# and XML so it is a little abacadabra for me. So I am
looking for a piece of code what do what you mean.

Gerrit


.



Relevant Pages

  • Re: Using Comma Separated Values to de-serialize a DataSet
    ... OpenNETCF.TextDataAdapter and a csv file. ... If you can't get the load time down much, be sure to have a nice splash ... Depending on the device ... performance gap between XML and CSV isn't so dramatic (or even apparent ...
    (microsoft.public.dotnet.framework.compactframework)
  • Re: problem with XML DOM load command
    ... with invalid XML and I'm getting suspicious that something in a QFE ... has busted MSXML and its exception processing. ... © 2003 Microsoft Corporation. ... >> So this exception is on your main thread where you're doing the load. ...
    (microsoft.public.windowsce.embedded.vc)
  • Re: Word Searching XML
    ... which will be somewhat interactive and can not expected to load ... we are trying to search XML node and its ... Microsoft Online Community Support ... where an initial response from the community or a Microsoft Support ...
    (microsoft.public.office.developer.com.add_ins)
  • Re: Saving program state in executable
    ... UML or OWL data using XML's DOM model, it takes quite a while to load ... The overhead is mostly the textprocessing and parsing of the XML models. ... 'const' record, or set of records, at compile time, and that might be ... knows it is one block of memory (assuming it doesn't contain e.g. ...
    (comp.lang.pascal.misc)
  • Memory limitation with owc?
    ... spreadsheets that I want to load into memory. ... loading a number of large xml files. ...
    (microsoft.public.office.developer.web.components)