473,388 Members | 1,346 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,388 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 12 '05 #1
2 9338
Did you manage to solve it? I am facing the same problem, so if you found a
solution, please could you let me know?

"http://www.visual-basic-data-mining.net/" wrote:
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 12 '05 #2
http://www.visual-basic-data-mining.net/forum wrote:
<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>


Load XML into XmlDocument, create and append new data and save it back.
See
http://msdn.microsoft.com/library/de...NodesInDOM.asp
how to create new nodes in XmlDocument.

--
Oleg Tkachenko [XML MVP]
http://blog.tkachenko.com
Nov 12 '05 #3

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: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
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: 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?
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
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

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.