We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. Image for the cookie policy date

Error when setting allowEditing:false and showRibbon:false in spreadsheet initialization


When I add "allowEditing: false" to the initialization of a spreadsheet, I get the following error when I first click a cell and the cells can't be selected:

Uncaught TypeError: Cannot read property 'html' of null_mouseDownHandler 
@ ej.web.all.min.js:10(anonymous function) 
@ ej.web.all.min.js:10dispatch 
@ jquery-2.1.4.min.js:3r.handle 
@ jquery-2.1.4.min.js:3

It can be reproduced by adding "allowEditing: false" to this example: http://js.syncfusion.com/demos/web/#!/azure/spreadsheet/defaultfunctionalities

Instead I tried setting this after initialization with $('#spreadsheet').data('ejSpreadsheet').option({allowEditing: false}) and I had "showRibbon: false" in the initialization and then I could select cells, but I get the following error:

Uncaught TypeError: Cannot read property 'find' of undefined_setModel 
@ VM2228 ej.web.all.min.js:10setModel @ VM2228 ej.web.all.min.js:10option 
@ VM2228 ej.web.all.min.js:10loadComplete 
@ VM2275 gbhvkzeb:22_trigger 
@ VM2228 ej.web.all.min.js:10_initComplete 
@ VM2228 ej.web.all.min.js:10_init 
@ VM2228 ej.web.all.min.js:10(anonymous function) 
@ VM2228 ej.web.all.min.js:10n.fn.(anonymous function) 
@ VM2228 ej.web.all.min.js:10(anonymous function) 
@ VM2275 gbhvkzeb:4j 
@ VM2218 jquery-2.1.4.min.js:2fireWith 
@ VM2218 jquery-2.1.4.min.js:2ready 
@ VM2218 jquery-2.1.4.min.js:2I 
@ VM2218 jquery-2.1.4.min.js:2

Aside from the error in the console, there didn't seem to be any behaviour effects. I noticed that without setting "showRibbon: false" I would not get the error. I moved it to after the initialization like so: $('#spreadsheet').data('ejSpreadsheet').option({allowEditing: false, showRibbon: false}) and that removed the error and kept the desired behaviour. I can keep this solution until this is fixed for initialization settings.


1 Reply

SK Shanmugaraja K Syncfusion Team September 14, 2016 08:47 AM UTC

Hi Gabriel, 

Thanks for using Syncfusion products. 

We have considered this “Script error while disable showRibbon and allowEditing an initial load” as an issue and a support incident has been created under your account to track the status of this requirement. Please log on to our support website to check for further updates. 

Shanmugaraja K 

Live Chat Icon For mobile
Up arrow icon