473,395 Members | 1,526 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,395 software developers and data experts.

[.Net 2.0] XML -> DataSet - iteration issue

Hi all,

I have the following xml file...

<?xml version="1.0" encoding="utf-8" ?>

<Assembly>

<!--
' The name of the product/application/resource.
' Value is required
-->

<Product>UHBristol Intranet Application Template</Product>

<!--
' A description of the product, what its used for, by who, non technical
' Value is required
-->

<Description>Template for all future UHBristol Intranet
Applications.</Description>

<!--
' The first year of copyright, ie, the year the product was released
' Value is required
-->

<FirstYearOfCopyright>2008</FirstYearOfCopyright>

<!--
' Copyright text to be displayed on template
' Value is required
-->

<Copyright>UHBristol [ University Hospitals Bristol NHS Foundation
Trust ]. All rights reserved.</Copyright>

<!--
' Version information for an assembly consists of the following four
values:
'
' Major Version
' Minor Version
'
' Example: 1.1
-->

<Version>1.0</Version>

<History>
<Release>
<Version>1.0</Version>
<Description>Initial Release</Description>
<Changes>
<Change></Change>
<Change></Change>
<Change></Change>
</Changes>
</Release>

<Release>
<Version>0.8</Version>
<Description>Pilot Beta</Description>
<Changes>
<Change></Change>
</Changes>
</Release>

</History>

</Assembly>

I've just come across the dataset.ReadXml method and like the look of it as
a good way of grabbing the content of the xml file ready to iterate/parse.

I've had a look at the contents of the dataset after reading in the above
file....and I'm happy with most of it... apart from the 5th table that it
creates which is the "Change" table.... based on the above it will contain 4
rows... how do I determine which of those 4 rows (ie, each <change></change>
node above) belong to the appropriate <Releasenode?

I saw a ParentRelations.ParentTable - but if I have to put in a hell of a
load of checks to check which table we're working through then its not far
from the piles of code I'd already written (and will probably now be
binning) that was parsing the xml file node by node previously (without the
dataset)..

I was hoping to just For Each DataRow In DataTable.Rows kinda thing to get
the information I require...

Any information would be appreciated...

Kind regards

Rob Meade

Aug 18 '08 #1
0 780

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

Similar topics

3
by: Vico | last post by:
Hi! I have a windows forms application and , what I basically do is: 1.- Instanciate a DataSet. 2.- Instanciate a XMlDataDocument attaching the DataSet to it. 3.- Load XmlDataDocument with a...
2
by: Ian Griffiths | last post by:
I have been given a schema, instances of which I'm required to be able to consume and generate. I'd like to be able to manipulate these instances as DataSets internally in my application. The...
6
by: Christoph Duesmann | last post by:
Hi ! Here's my problem in english :-) I want to convert the mssecure.xml file from Microsoft into an dataset to store it in an SQL-Database. My code in VB looks like this : Dim ds As New...
0
by: thomas | last post by:
I must be doing something obvious wrong here, but: I perform a query to retrieve a dataset - I want to archive this in a SQL field for seperate retrieval later, while the original data may have...
4
by: Mark | last post by:
Hi, does anyone know how I can simply get the dataset that is bound to a DataGrid? Something like... DataSet dsDataSet = DataGrid1.Tables........... Thanks Mark
4
by: Shapper | last post by:
Hello, I have a XML file that includes the node <item>: .... <title>...</title> <url>...</url> <item> <title>title 01</title> <description>description 01</description> </item>
3
by: Adam | last post by:
Hi All, What is the most acceptable way of iterating through a DataSet Tables Row Collections Manually? As in: 'fill data adapter object with dataset info Da = New SqlDataAdapter(Cmd)...
5
by: David Harris | last post by:
I am developing a type of data warehouse. Basically, we have 20 client survey machines that are each separated from the server by space and lack of network. Yet both need to speak to each other...
0
by: =?Utf-8?B?TXlMYWJSdWJ5?= | last post by:
I am developing an application that will be able to be used offline from the SQL server and am trying to come up with a good way to do this. My thought at this moment is to basically work "offline"...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
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: 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
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
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
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...

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.