Re: Read XML File
- From: "Gerrit" <gsnel_geentroep@xxxxxxxxxxx>
- Date: Tue, 24 Oct 2006 01:07:31 +0200
<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
.
- Follow-Ups:
- Re: Read XML File
- From: Morten Wennevik
- Re: Read XML File
- References:
- Read XML File
- From: Gerrit
- Re: Read XML File
- From: ssamuel
- Read XML File
- Prev by Date: Re: XML serialisation - error reflecting type
- Next by Date: Can access Web Page but not Web Service
- Previous by thread: Re: Read XML File
- Next by thread: Re: Read XML File
- Index(es):
Relevant Pages
|