I have got a file called xmlfile.xml:
<Personen>
<Person>
<Vorname>Manfred</Vorname>
<Telefon/>
<Zuname>Fischer</Zuname>
<Alter>45</Alter>
<Adresse Ort="Bonn" Strasse="Neuestr.34"></Adresse>
</Person>
</Personen>
There are two problems. First of all are the fields of '' variable. So maybe the xmlfile contains 3 persons or another value (of course it contains at least one). Now I need to print out the 'Vorname' of each Person, how can I do so? I tried this code (just a short view):
reader.ReadToFollowing("Person");
string isbn = reader.GetAttribute("Alter");
Console.WriteLine("age: " + isbn);
Console.ReadLine();
But it doesn't print out the age (Alter), how to get it working to print out the age of each person, in case there are more then one.