Spreadsheet Export to Excel not working any more

1 Answer 51 Views
Spreadsheet
Daniel
Top achievements
Rank 1
Daniel asked on 21 Jan 2025, 07:10 AM

Using KendoUI latest version, the exportToExcel function in Spreadsheet seems broken.

Console shows error:

 

George
Top achievements
Rank 3
Bronze
Bronze
Iron
commented on 21 Jan 2025, 04:23 PM | edited

Daniel,

That version 2024.4.1112 no longer contains JSZip.js. In my program I am still using v 2023.3.1010

...and you can see the JSZip.js is part of the Kendo package or library. You need to find JSZip.js yourself unfortunately and place it in your project. I found it here:  jszip/dist at main · Stuk/jszip · GitHub . I was testing version 2024.3.1015 as I routinely do to evaluate what it would take to update my project.... and it barfed while doing an import. There is some documentation on this in the Telerik site.

 

I used the minified version and plopped it in my project back where it used to be:


Also see:  https://stuk.github.io/jszip for documentation.

I cannot guarantee it will work! But you have to get it and put it in your project. Your milage may vary. Also see:
Spreadsheet - a problem with fromFile function and JSZip library in Kendo UI for jQuery | Telerik Forums

Again finding the JSZip and putting it in manually worked for me....hopefully this might get you back on the road.

Daniel
Top achievements
Rank 1
commented on 22 Jan 2025, 12:08 PM

George, thanks for your response.

I verified JSzip 3.10 is already included in my project (using yarn package manager). I can instantiate a new JSZip instance in Chrome console. Removed the dependency, and now receive a "JSZip is not defined" error as expected, when trying to manually instantiate it.

However, the message when trying to execute the Spreadsheet export remains the same:


index-esm.js:23176 Uncaught TypeError: options.Workbook is not a constructor
    at next (index-esm.js:23176:1)
    at Workbook.saveAsExcel (index-esm.js:23170:1)
    at SpreadsheetWidget.saveAsExcel (index-esm.js:23741:1)
    at init.saveAsExcel (kendo.spreadsheet.js:5575:1)
    at exportExcel (<anonymous>:34:67)

Nikolay
Telerik team
commented on 24 Jan 2025, 07:37 AM

Hi George,

Thank you for the input!

Nikolay

1 Answer, 1 is accepted

Sort by
0
Nikolay
Telerik team
answered on 24 Jan 2025, 07:36 AM

Hello Daniel,

This is a known bug and it has been addressed and the fix will be available with the upcoming relate scheduled for February.

https://github.com/telerik/kendo-ui-core/issues/8072

Until then, you can use the workaround from the next Dojo: https://dojo.telerik.com/fDhKflqE/2

Regards,
Nikolay
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
Spreadsheet
Asked by
Daniel
Top achievements
Rank 1
Answers by
Nikolay
Telerik team
Share this question
or