Wrox Programmer Forums
Go Back   Wrox Programmer Forums > XML > XSLT
|
XSLT General questions and answers about XSLT. For issues strictly specific to the book XSLT 1.1 Programmers Reference, please post to that forum instead.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the XSLT section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old July 14th, 2006, 12:16 AM
Authorized User
 
Join Date: Mar 2006
Posts: 13
Thanks: 0
Thanked 0 Times in 0 Posts
Default How to convert Excel(xls) contents into HTML

I have generated local report using SQL REPORTING Services and get rendered it as below:
Method Render()
Start
 Warning[] warnings;
        string[] streamids;
        string mimeType;
        string encoding;
        string extension;

        byte[] bytes = ReportViewer1.LocalReport.Render("Excel",
                 null, out mimeType, out encoding,
                 out extension,
                 out streamids, out warnings);

End
End Method
Now I have the bytes of Excel file, I want to convert it into HTML response. How can I do this, Pl assist me.

Thanks,
Manish


 
Old July 29th, 2013, 04:42 AM
Registered User
 
Join Date: Jul 2013
Posts: 6
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Hi, you can try this C# Excel component which has a really nice API for converting Excel to a HTML file in C#.
Here is how you can stream your Excel file bytes to a client:
Code:
MemoryStream ms = new MemoryStream(bytes);
ExcelFile.Load(ms, LoadOptions.XlsDefault).Save(this.Response, SaveOptions.HtmlDefault);





Similar Threads
Thread Thread Starter Forum Replies Last Post
convert shopping Cart contents to string paulk ASP.NET 2.0 Basics 0 July 1st, 2006 08:30 AM
import xls or html Nathalie Beginning VB 6 3 April 26th, 2006 11:48 AM
convert PDF file to XLS for Excel crmpicco Classic ASP Basics 2 November 30th, 2005 05:51 AM
XLS output to CHTML instead of HTML athanatos XSLT 1 February 9th, 2005 06:29 AM
Convert xls for vba state VB How-To 1 September 30th, 2004 06:29 AM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.