Creating xml and convert to xls (excel) , xml Gent, Belgium
  • 13 years ago
    Hi all!

    I have the following question:

    I want to know if it's possible to create an xls file from an xml file.  I've already managed to write the asp code to create an xml file, fill it with data from a gridview and save it to a directory on the webserver. So now i've got the file export.xml on my webserver.

    But how can i create an xls file of this xml file?

    Or is it maybe possible to create an xls file instantly from a gridview?

    Thanks in advance!


  • 13 years ago
    The easiest way if you are doing it on the fly and as this is in the ASP thread i presume it is from a web based app is to simply change the MIME type of the document to that of an XLS type. The page will then render as an xls document. It may also be worth considering turning off the viewstate as you wont be needing it and simply bind your generated xml to a datadrid

Post a reply

Enter your message below

Sign in or Join us (it's free).


Why not write for us? Or you could submit an event or a user group in your area. Alternatively just tell us what you think!

Our tools

We've got automatic conversion tools to convert C# to VB.NET, VB.NET to C#. Also you can compress javascript and compress css and generate sql connection strings.

“An idiot with a computer is a faster, better idiot” - Rich Julius