How to Use IPdfExportRenderer or ISpreadExportRenderer Interfaces while exporting?

1 Answer 71 Views
GridView
Ali
Top achievements
Rank 1
Ali asked on 18 Apr 2023, 12:52 AM

Hello!

There is a little trouble while exporting Telerik RadGridView Rows to PDF or Spreadsheet. The problem with this code is down below.

The question mark parameter is required ISpreadExportRenderer Interface. How to implement this condition. Kindly Explain using Code.

GridViewSpreadExport gridViewSpreadStreamExport = new GridViewSpreadExport(this.gvList); gridViewSpreadStreamExport.RunExport(filename, ?)

1 Answer, 1 is accepted

Sort by
0
Dinko | Tech Support Engineer
Telerik team
answered on 19 Apr 2023, 12:51 PM

Hi Ali,

You need to pass SpreadExportRenderer class as a parameter. You can check the Spread Export help article for more information regarding the export which utilizes the RadSpreadProcessing library.

GridViewSpreadExport spreadExporter = new GridViewSpreadExport(this.radGridView1);
SpreadExportRenderer exportRenderer = new SpreadExportRenderer();
spreadExporter.RunExport("D:\\exportedFile.xlsx", exportRenderer);

Regards,
Dinko | Tech Support Engineer
Progress Telerik

Love the Telerik and Kendo UI products and believe more people should try them? Invite a fellow developer to become a Progress customer and each of you can get a $50 Amazon gift voucher.

Tags
GridView
Asked by
Ali
Top achievements
Rank 1
Answers by
Dinko | Tech Support Engineer
Telerik team
Share this question
or