Last post Sep 23, 2015 05:47 AM by Zhi Lv - MSFT
Aug 18, 2014 12:25 AM|geet|LINK
How Can one create Excel from XML. One more query: Can we write only certain tags in XML while creating XML? For Example:
I want to write say only 2 tags in XMLsay Name & Designation.
I am creating XML like beow:
System.Xml.Serialization.XmlSerializer serializerRA = new System.Xml.Serialization.XmlSerializer(typeof(UserBE));
XmlWriterSettings settings = new XmlWriterSettings();
settings.Encoding = new UnicodeEncoding(false, false);
settings.Indent = true;
settings.OmitXmlDeclaration = true;
StringWriter textWriterRA = new StringWriter();
if (UserLoginList != null)
foreach (UserBE xUserBE in UserLoginList)
using (XmlWriter xmlWriter = XmlWriter.Create(textWriterRA, settings))
Aug 18, 2014 02:05 AM|aspnet2sams|LINK
Try with data transformation services of Sequel Server
Aug 18, 2014 02:45 AM|aspnet2sams|LINK
a uniform resource locator that seem relate to XML to Excel conversion http://forums.asp.net/t/2001688.aspx it indicates use of Open XML and A Feature of third party controls
Sep 22, 2015 02:26 AM|aspnet2sams|LINK
are you active?
Sep 23, 2015 05:47 AM|Zhi Lv - MSFT|LINK
From your description, if you want to convert existing xml file to excel file. You could try to use DataTable.ReadXml method to import xml file into the data table. Then, export data table to excel file.
Here are some tutorials, you could refer to them:
export to excel:
If you want to use the xml string. First, you could extract the relevant data and insert them into datatable, then refer to the following links to export to excel file.