This is a migrated thread and some comments may be shown as answers.
Unable to add header cells in spreadsheet binded to datasource
1 Answer 7 Views
This is a migrated thread and some comments may be shown as answers.
Alejandro
Top achievements
Rank 1
Alejandro asked on 18 Dec 2020, 05:02 PM

Hello everyone,

I am using Kendo 2020.2.513 and I want to do something as in this Dojo: https://dojo.telerik.com/EnuyodAQ

In fact, I am perfectly able to reproduce that code in my project. However, as soon as I change the URL with the one that is providing my data, the code is failing. Data is binded correctly to the spreadsheet, but the next error occurs:

kendo.all.js:139181 Uncaught Error: Shifting nonblank cells off the worksheet is not supported!
at init.insertRow (kendo.all.js:139181)

 

I have even updated the server code to return provide a Jsonp output (so far, it was normal Json). When accessing the data URL directly, with a callback query parameter, the output is consistent with the one in the Dojo example (https://demos.telerik.com/kendo-ui/service/Products?callback=someCallbackFn&_=1234). 

The only difference I can come up with is that, since I am testing locally, my server is serving the content without SSL/TLS (no HTTPS). But I don't think that is relevant at this point. 

Do you have any idea of what can be going on?

 

1 Answer, 1 is accepted

Sort by
0
Veselin Tsvetanov
Telerik team
answered on 22 Dec 2020, 03:36 PM

Hi Alejandro,

The error observed on the console means that with the insertRow() command you are trying to insert a line in a Sheet that has its last row populated with values, formulas, and/or formatting. As the number of rows in the Spreadsheet widget is fixed, that is a not supported action. You will observe exactly the same error in the Dojo when setting the total number of rows in the Sheet to 78:

    $("#spreadsheet").kendoSpreadsheet({
      columns: 20,
      rows: 78,

https://dojo.telerik.com/EnuyodAQ/3

Regards,
Veselin Tsvetanov
Progress Telerik

Virtual Classroom, the free self-paced technical training that gets you up to speed with Telerik and Kendo UI products quickly just got a fresh new look + new and improved content including a brand new Blazor course! Check it out at https://learn.telerik.com/.

Asked by
Alejandro
Top achievements
Rank 1
Answers by
Veselin Tsvetanov
Telerik team
Share this question
or