Click here to Skip to main content
Rate this: bad
good
Please Sign up or sign in to vote.
See more: C# XML
Hi, Actuvally i am storing a data in variables ,i want to diaply those data into xml file .how to do ?
plz help me
 
ex:stiring A="john"
string B="petter"
string C="gavaskar"
 

this above data i want to dispaly in xml how to do?help me
Posted 8-May-13 22:31pm
Comments
KM Perumal at 9-May-13 3:57am
   
what output format u want??
Orcun Iyigun at 9-May-13 4:06am
   
Do you want your xml like the following:
-names
-name
John
-/name
-name
Petter
-/name
-name
Gavaskar
-/name
-/names
Give us a sample format so we can help you better?
Juhi Paunikar at 9-May-13 6:17am
   
Create datatable of your string data then you can easily convert it in to xml using writexml method.

1 solution

Rate this: bad
good
Please Sign up or sign in to vote.

Solution 1

Quote:
,i want to diaply those data into xml file
I assume you meant: "I want to store them into a XML file".
It is very easy to create yourself an a XML file, directly using its Write method. Or you may follow a more 'sophisticated' approach using the XmlSerializer[^] class.
  Permalink  

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
0 OriginalGriff 365
1 Sergey Alexandrovich Kryukov 329
2 CPallini 270
3 Afzaal Ahmad Zeeshan 204
4 DamithSL 194
0 OriginalGriff 5,515
1 DamithSL 4,451
2 Maciej Los 3,902
3 Kornfeld Eliyahu Peter 3,480
4 Sergey Alexandrovich Kryukov 3,175


Advertise | Privacy | Mobile
Web01 | 2.8.141216.1 | Last Updated 9 May 2013
Copyright © CodeProject, 1999-2014
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100