How to build hierarchical XML from DataSet Options

gamesforums

Usenet Archive
Joined
Sep 29, 2007
Messages
10
Reaction score
0
Hi!

I need to build the following XML structure in my businnesslayer in VB.NET.

<ProductionDataExtract>
<Region region="South">
<MonthToDate>
<ProductionBudget>2338</ProductionBudget>
</MonthToDate>
</Region>
</ProductionDataExtract>

My problem is that when i use DataSet.getXML i will get a flat file structure on the xml returned.

What I want is the following:
<ProductionDataExtract> (Root node, parent)
<Region> (child node of ProductionDataExtract, but parent to MonthToDate) <MonthToDate> (child node of Region, but parent to ProductionBudget) <ProductionBudget> (child node of MonthToDate)

I have tried using ADO.NET's DataRelation Object, but of course this wont work as I have no Key's between the parent and child elements.

So any suggestion are really appreciated! :)

Regards,
Mcad
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
548,049
Messages
3,104,243
Members
248,133
Latest member
DujonT

Latest Threads

Top