473,395 Members | 1,488 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.

VB.NET: Writing attribute and Elements to Xml

Say i have this Xml file

<Books>
<Book type="1">
<Author>Peter</Author>
<Section>1</Section>
</Book>
</Books>

how to create another automatic set of IDs and datas for the Xml tag so that
when i type in another set of data...

The content of the Xml file will become:

<Books>
<Book type="1">
<Author>Peter</Author>
<Section>1</Section>
</Book>
<Book type="2">
<Author>John</Author>
<Section>2</Section>
</Book>
</Books>

Thanks

--
toytoy - forum member
http://www.visual-basic-data-mining.net/forum
Nov 21 '05 #1
1 913
One method is to create a strongly type dataset and add values to the
dataset. When finished, call the dataset's WriteXML method.

--
Gerry O'Brien [MVP]
Visual Basic .NET(VB.NET)


"http://www.visual-basic-data-mining.net/forum" <si******@gmail.com> wrote
in message news:OM**************@TK2MSFTNGP15.phx.gbl...
Say i have this Xml file

<Books>
<Book type="1">
<Author>Peter</Author>
<Section>1</Section>
</Book>
</Books>

how to create another automatic set of IDs and datas for the Xml tag so
that
when i type in another set of data...

The content of the Xml file will become:

<Books>
<Book type="1">
<Author>Peter</Author>
<Section>1</Section>
</Book>
<Book type="2">
<Author>John</Author>
<Section>2</Section>
</Book>
</Books>

Thanks

--
toytoy - forum member
http://www.visual-basic-data-mining.net/forum

Nov 21 '05 #2

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

Similar topics

3
by: Roy Adams | last post by:
Hi I'm reposting this question because for some reason can't post follow up question to this thread. What I'm trying to do is put the value and text from a a select in to a text field and to a...
2
by: Antonio Collins | last post by:
Does anyone know of a site that details the variances between .NET's schema implementation and other tools? I have a dataset and schema that validates perfectly via MSXML4 but fails validation in...
5
by: Saga | last post by:
Hi all, I just read the thread by the same name posted on Jun 15, 9:45 AM, but I am looking at it from a different point of view. I came across this question in terms of functionality. Are VB and...
7
by: Alan Silver | last post by:
Hello, I am a complete and utter newbie at ASP.NET, so please forgive any stupid questions ;-) I am just trying to get my head around the whole web forms business, but have run into a...
12
by: Alex D. | last post by:
How can I stop asp.net from rendering XHTML istead of HTML? My javascripts are rendering wrong because of that. It is rendering &amp; to clients instead of &. Any help? Thanks, Alejandro.
13
by: John Rivers | last post by:
Here is an example of what I am talking about: asp.net takes what is a very simple, powerful and flexible concept, http request/response with html for presentation and turns it into a...
2
by: Jobs | last post by:
Download the JAVA , .NET and SQL Server interview with answers Download the JAVA , .NET and SQL Server interview sheet and rate yourself. This will help you judge yourself are you really worth of...
0
by: shamirza | last post by:
· When was .NET announced? Bill Gates delivered a keynote at Forum 2000, held June 22, 2000, outlining the .NET 'vision'. The July 2000 PDC had a number of sessions on .NET technology, and...
0
by: shamirza | last post by:
· What is view state and use of it? The current property settings of an ASP.NET page and those of any ASP.NET server controls contained within the page. ASP.NET can detect when a form is requested...
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: 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:
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.