This is a migrated thread and some comments may be shown as answers.

Reportviewer export to Excel Error

16 Answers 653 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
Vijayasarathi
Top achievements
Rank 1
Vijayasarathi asked on 06 Nov 2012, 11:20 AM
Hi Team, 

Issue : When I am trying to export to excel its getting request timeout error. 

Description :
Report viewer has 240 pages and it was loaded successfully and I can able to export PDF also. Only I am getting error when I am trying to export to Excel
and when I am trying to debug through source code its working fine. Only I am facing this issue in Production (Live).
we are using graph and table format as well. Please advise me to resolve this issue.


-
V S

16 Answers, 1 is accepted

Sort by
0
Steve
Telerik team
answered on 08 Nov 2012, 05:05 PM
Hi,

If the problem only occurs on your server, this means that you're using a different web.config file with different timeout setting. Make sure the timeout of your web application and the connectionTimeout property of your sql server are set to enough time (e.g. 10 mins) so that the excel document can be generated properly. Have in mind that handling reports (be it with large data or large number of report items) usually requires additional resources in terms of powerful CPUs, and enough memory to handle all the operations. As far as the processing time and consumed memory is concerned, the complexity of the report layout, the complexity of the data calculations (aggregates, conditional formatting),  the rendering media, the size of the generated document (in pages), and the capabilities of the underlying machine are crucial.

In general, Telerik Reporting is an embedded reporting engine, which primary goal is to analyze data and represent it in a human-readable format that is also suitable for printing. During this process, certain complex layout and paging rules are applied, so the great flexibility offered by the reporting engine comes at a price: increased processing times and memory footprint. You should agree that dumping millions of records from a database at once hardly fit in the category of report generation. Perhaps in your specific scenario another component such as our RadGrid control might be more appropriate, moreover our RadGrid control offers several export options.

Regards,
Steve
the Telerik team

HAPPY WITH TELERIK REPORTING? Do you feel that it is fantastic? Or easy to use? Or better than Crystal Reports? Tell the world, and help fellow developers! Write a short review about Telerik Reporting and Telerik Report Designer in Visual Studio Gallery today!

0
Vijayasarathi
Top achievements
Rank 1
answered on 04 Dec 2012, 10:13 AM
Hi Team,

                As your suggetion, we tried everythig. System is getting the same issue. if the reports count is more than 200 than, its getting the timeout error. could you please suggest me to write customized code to export excel format.?
and give me an  example code.  (in C#)

Thanks
VS
0
Steve
Telerik team
answered on 05 Dec 2012, 01:47 PM
Hello VS,

To export a Telerik report from a Silverlight application without a Silverligh Report Viewer you have to instantiate the Telerik.Reporting.Service.SilverlightClient.ReportServiceClient class, which plays the role of proxy to the Telerik Reporting WCF Service. More information and sample code is available in the  Exporting Report in Silverlight help article.

Greetings,
Steve
the Telerik team

HAPPY WITH TELERIK REPORTING? Do you feel that it is fantastic? Or easy to use? Or better than Crystal Reports? Tell the world, and help fellow developers! Write a short review about Telerik Reporting and Telerik Report Designer in Visual Studio Gallery today!

0
Vijayasarathi
Top achievements
Rank 1
answered on 21 Jan 2013, 01:59 PM
Hi Steve,
We have resolved that export to excel issue. Thanks a lot to you.
and we got another issue on same exported excel file. That is, report viewer has the following colors for RED, GREEN,  YELLOW
RGB - GREEN  [ 0,130,74 ]
RGB - RED [212,146,18 ]
RGB - YELLOW [ 222, 135 , 3 ]

I can able to see the exact color in website. but when I am looking the exported excel file, it is showing as different colors.
I have attached the screenshot. Please see and advise me.

-
V S
0
Accepted
Steve
Telerik team
answered on 22 Jan 2013, 03:53 PM
Hi VS,

You're most likely exporting to the binary XLS format, which has various limitations including such for the supported color palette. Those limitations are outlined in the Design Considerations for Excel Rendering help article.

To avoid this limitation, use the new OpenXML format (XLSX) instead when exporting the report.

Kind regards,
Steve
the Telerik team

HAPPY WITH REPORTING? Do you feel that it is fantastic? Or easy to use? Or better than Crystal Reports? Tell the world, and help fellow developers! Write a short review about Telerik Reporting and Telerik Report Designer in Visual Studio Gallery today!

0
Vijayasarathi
Top achievements
Rank 1
answered on 25 Jan 2013, 05:57 AM
Hi Steve,

    Issue Resolved. Thanks a lot.
0
Vijayasarathi
Top achievements
Rank 1
answered on 25 Feb 2013, 09:19 AM
Hi Steve,

I have tried to install Open XML sdk in Local. it was working perfectly. I can able to export to excel (XLSX format)  with correct colors. 
Meantime, we have some internal issue to install Open XML SDK on server. So, this issue is still with me. I couldn't pass to live. 

Do you have any other solutions for (xls format).?  except install  Open XML SDK.. pls

Thanks and regards.
VS
0
Accepted
IvanY
Telerik team
answered on 28 Feb 2013, 08:46 AM
Hi Vijayasarthi,

Since we are relying on Open XML you will need the DocumentFormat.OpenXml assembly on your server.

.XLS (binary format) supports only a limited count of colors and that is a restriction that has no workarounds. You will have to either add the forementioned assembly or to create your reports having in mind the color limitation imposed by Excel 97 -2003 format.

Greetings,
IvanY
the Telerik team

See what's new in Telerik Reporting Q1 2013. Register for the March 4 webinar to witness the impressive new visualizations in Telerik Reporting. Just for fun, 10 webinar attendees will be randomly selected to win a Telerik T-shirt and a $50 Gift Certificate to ThinkGeek. Register now! Seats are limited!

0
Vijayasarathi
Top achievements
Rank 1
answered on 28 Feb 2013, 10:16 AM
Hi 

I added the  DocumentFormat.OpenXml assembly to my solution instead of install OpenXMLSDK on server. its working perfectly.

Thanks a lot.  :)
 VS
0
Scott Salyer
Top achievements
Rank 1
answered on 15 Aug 2013, 02:24 PM
I was told that there was a way to switch the export from ExcelML to HTML format which is supposed to be much faster when exporting a lot of pages. How does one accomplish that?
0
Stef
Telerik team
answered on 20 Aug 2013, 01:38 PM
Hello Scott,

In the Rendering Extensions help article you can find a list with the available rendering formats. In order to use the HTML rendering extension you will have to export the report document programmatically as explained in the Exporting Report Programmatically help article(Exporting a report to a multi document format).

I hope this helps.

Regards,
Stef
Telerik

Have you tried the new visualization options in Telerik Reporting Q2 2013? You can get them from your account.

0
Sandeep
Top achievements
Rank 1
answered on 22 Nov 2013, 11:34 AM
Hi Vijayasarthi,

Can you please share a piece of code as i also have the same issue of exporting to excel. 

Thanks,
Sandeep
0
Stef
Telerik team
answered on 22 Nov 2013, 01:23 PM
Hello Sandeep,

Both XLS and XLSX rendering extensions can be used as in the first code snippet of the the Exporting Report Programmatically help article(Exporting a report to a single document format) - just set the needed rendering extension name.

In the case of XLSX you will need to add references to the DocumentFormat.OpenXml assembly as elaborated by my colleagues in this forum thread.

Let us know if you have any further questions.

Regards,
Stef
Telerik

New HTML5/JS REPORT VIEWER with MOBILE AND TOUCH SUPPORT available in Telerik Reporting Q3 2013! Get the new Reporting version from your account or download a trial.

0
Vijayasarathi
Top achievements
Rank 1
answered on 27 Nov 2013, 08:12 AM
Just  put this following dll in your project bin folder,
DocumentFormat.OpenXml.dll
Telerik.Reporting.OpenXmlRendering.dll

xlsx format will load automatically. 


You can enable / disable the export formats like below,

<Telerik.Reporting>
    <Extensions>
      <Render>
        <Extension name="IMAGE" visible="false"></Extension>
        <Extension name="RTF" visible="false"></Extension>
        <Extension name="CSV" visible="false"></Extension>
        <Extension name="MHTML" visible="false"></Extension>
        <Extension name="XPS" visible="false"></Extension>
        <Extension name="XLS" visible="false"></Extension>
        <Extension name="PPTX" visible="false"></Extension>
        <Extension name="DOCX" visible="false"></Extension>
      </Render>
    </Extensions>
  </Telerik.Reporting>
0
Gopi
Top achievements
Rank 1
answered on 13 Jan 2015, 03:49 PM
Hi Team,

I am using Telerik Reportviewer to show report, and when I am trying to export my report to PDF or Excel I am getting error. My report has approximately 200 pages. Is there anyway to increase time limit amount for this control in web.config or anywhere else?

I have already increase amounts in IIS server.
I am looking for solution to this error.
0
Hinata
Top achievements
Rank 1
answered on 16 Jan 2015, 12:28 PM
Hi Gopi

Check the second post in this thread. It answers your question about increasing the time limit.
Tags
General Discussions
Asked by
Vijayasarathi
Top achievements
Rank 1
Answers by
Steve
Telerik team
Vijayasarathi
Top achievements
Rank 1
IvanY
Telerik team
Scott Salyer
Top achievements
Rank 1
Stef
Telerik team
Sandeep
Top achievements
Rank 1
Gopi
Top achievements
Rank 1
Hinata
Top achievements
Rank 1
Share this question
or