473,398 Members | 2,389 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,398 software developers and data experts.

node iterator question (simple)

i have some xml like this:

<departments>
<department name="finance">
<employee name="tom hanks" age="23"/>
<employee name="tom selleck" age="43"/>
</department>
<department name="admin">
<employee name="nicole kidman" age="33"/>
<employee name="tom cruise" age="44"/>
<employee name="harrison ford" age="42"/>
<employee name="nicholas cage" age="23"/>
</department>
</departments>
i want to loop through each "department" and then loop through each of its
corresponding "employees" picking of the attribute values. how can i do
this in .net using the xpathnavigator and xpathnodeiterator objects. i have
managed to retrieve the department name, but i am stuck trying to get
information out the its children.

many thanks.
Nov 12 '05 #1
0 975

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

38
by: Grant Edwards | last post by:
In an interview at http://acmqueue.com/modules.php?name=Content&pa=showpage&pid=273 Alan Kay said something I really liked, and I think it applies equally well to Python as well as the languages...
0
by: Robert Sturzenegger | last post by:
// Hello! typedef deque<int> D; typedef D::iterator Iter; D d; Iter iter; // here hundreds of elements pushed back to d
0
by: CoolPint | last post by:
I am trying to write a generic heapsort (of course as a self-exercise) with Iterator interface: something like blow.... But I got into trouble finding out the Iterator to the Child node. If...
1
by: Omkar Singh | last post by:
I have want to read a xml file node by node. How can I do it? I am using following code to load xml file. XmlDocument doc = new XmlDocument(); doc.Load(fileName);
2
by: Lupina | last post by:
I want to read certain node from xml file by the ID. It means taht I know the ID of person, and I want read all data that person (eg: name,mail...). persons.xml <?xml version="1.0"?>...
2
by: nicholas | last post by:
Hi folks, I'm diving into XPathNavigator.SelectDescendants method. There's a boolean type parameter matchSelf, and MSDN says "To include the context node in the selection, true; otherwise,...
7
by: andreas | last post by:
Hello, I have a problem with iterators in a fairly complex polygonal mesh data structure which is implemented using lists of geometric entities. However, the problem in itself is fairly simple:...
16
by: mailforpr | last post by:
How do I do that? The thing is, the only information I have about the iterator is the iterator itself. No container it is belonging to or anything. Like template<Iteratorvoid...
3
by: vasili | last post by:
hello All, I have a simple issue. I defined a custom container, that encloses a std::list, which in turn holds objects that are a simple abstraction of a six position array. Now, i would like...
0
by: Lie Ryan | last post by:
On Wed, 01 Oct 2008 10:46:33 -0400, Luis Zarrabeitia wrote: No (or I'm not aware of any). Why? Because for some iterable, it is not possible to know in advance its length (video data stream,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.