473,324 Members | 2,179 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,324 software developers and data experts.

XML related.

Hi,

I am fresher i have problem, who i can convert the text file into XML file formate. Please help me if you have any idea.

Harmeet Singh
Nov 17 '08 #1
3 942
balabaster
797 Expert 512MB
Um... define "text file" and "xml format"...

xml is syntactically very similar to html, except you can defined your own tags. What is the information in the text file you wish to have in XML?

I'm going to assume you have the data in some kind of datatable style format in your text file - maybe csv or something... hopefully the first line has headers.

In this case, just Google "load datatable from CSV". Once you have the data in a datatable you can just save the data out to an XML file using:

Assuming you've successfully done this and you've created a DataTable called "MyDataTable", use the WriteXml method to save the data out to an XML file:

C#
Expand|Select|Wrap|Line Numbers
  1. MyDataTable.WriteXml("MyOutputFile.xml");
VB
Expand|Select|Wrap|Line Numbers
  1. MyDataTable.WriteXml("MyOutputFile.xml")
Nov 17 '08 #2
Hi,

Thanks for reply. pls just give me details, how i can implement it my code.


Harmeet Singh
Nov 18 '08 #3
r035198x
13,262 8TB
You have already been given enough information to start writing your own code.
Nov 18 '08 #4

Sign in to post your reply or Sign up for a free account.

Similar topics

3
by: Jason | last post by:
I am trying to filter records in a primary form based on records in related tables. The data in the related tables is being displayed in the primary form through subforms. To be more specific, I...
2
by: Danial Juka | last post by:
Hi All, I am making a content management system in asp.net. I want to show max 5 related links to other articles that somehow relate to the current article. An example of what I am looking...
2
by: Jim in Arizona | last post by:
Usually, If i need special formatting, I don't use the datagrid control and use a loop that processes a table for each record read from the database (as in classic asp) like so: ...
9
by: clintonG | last post by:
The Barnes & Noble stores in and around Milwaukee, Wisconsin have removed or are removing all of the Microsoft platform programming and support magazines from their shelves. Not one single magazine...
3
by: ss | last post by:
hI, Where do I created the Session Related things in ASP.NET 2.0? How do I do that? Could anybody give some sample code? bye
1
by: David | last post by:
Hi, I have an MS Access app which lets me create a new product by copying data from another selected product. All works fine, except one of the copy updates which I cannot fathom. The code...
4
by: HLCruz via AccessMonster.com | last post by:
I am working with a database that has client information separated in to 4 related tables - tFolder, tAddress, tEmail, tPhone number. In addition there are related tables tGifts and tCalls. The...
3
by: stair | last post by:
I have 2 tables, 1 table containing a list of items and a second with list of documents related to the items and the status of those documents. It is valid to have no documents related to a...
11
misscrf
by: misscrf | last post by:
I have received data which contains similar records, where the customers have similar records. A customer, i.e. Jane Doe may have moved, or something, or a change to her account. When that happened...
0
by: cannonpm | last post by:
Greetings and salutations. I have developed an A2K3 MDB and have a search form modeled after Allen Browne's search form (http:// allenbrowne.com/ser-62.html). It works well except for records which...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
1
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
1
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
0
by: af34tf | last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 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 former...

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.