documenteditor Propertypane

i cannot get my head around


syncfusion.Ej2 19.4500.0.38


using the sample project i am getting a lot of these error messages

in this case clink on the property pane button


TypeError: Cannot read properties of undefined (reading 'style')

at HTMLButtonElement.onPropertyPaneClick (documenteditor-helper.js:826:26)


other msg are apearing

like


scripts default.js ,documenteditor-helper.js and ej.min.js are loaded


TypeError: Cannot read properties of undefined (reading 'containerWidget')

at e.get [as isInShape] (\scripts\ej2\ej2.min.js:1:6886606)

at e.checkFloatingItems (\scripts\ej2\ej2.min.js:1:5728356)

at e.getLineWidgetInternal (\scripts\ej2\ej2.min.js:1:5724998)

at e.getLineWidget (dscripts\ej2\ej2.min.js:1:5724015)

at e.updateCursor (\scripts\ej2\ej2.min.js:1:5735587)

at HTMLDivElement.onMouseMoveInternal (\scripts\ej2\ej2.min.js:1:5675065)



thanks and


3 Replies

SM Suriya Murugan Syncfusion Team January 31, 2022 08:19 AM UTC

Hi Rene, 

Please find the sample from below link: 

We couldn’t reproduce the reported issue. Can you please let us know if we done anything wrong? if yes, modify the sample and share to us. That will be helpful for us to recreate the same in our side and provide you the solution at the earliest. 

Regards, 
Suriya M. 



RE René January 31, 2022 07:50 PM UTC

This one is seems to continue twisting my head. I am following the sample Documenteditor MVC 1947153949 which is using SF.EJ2 16.3500.0.21, icopied the project ro a new one and updated the controls to my current version  19.4.0.38 and using SF.EJ2 19.4500.0.38


in the init process i found one function which concers me now and i can not figure out why.

In 

initializeToolbarItems this is the call 


 var tocElement = document.getElementById('toc').getElementsByTagName('div')[0];

 onTextWrapTOCButton(tocElement);


tocelement stays undefined as along the script all calls using  getElementsByTagName ('div')[0] staying undefined. therefore

onTextWrapTOCButton,

onTextWrap functions fail 

which at the end fails the whole init prozess and therefore the Pane is not initialised


as the 

initComponentAndWireEvent functions does not continue beyond 

initializeToolbarItems, never reaching this one 

initializeTocPane. So i strongly believe the catch is the call above


if you have any ideas, please


best regards



SM Suriya Murugan Syncfusion Team February 1, 2022 06:58 AM UTC

Hi Rene,


In old version, we have implemented properties pane and toolbar in sample level. After 17.X version, in latest version(19.4.0.38) also, we have implemented builtin properties pane and toolbar in source level. You can use DocumentEditorContainer to use it. 


Please find the sample from below link: 

Code snippet: 
@Html.EJS().DocumentEditorContainer("container").EnableToolbar(true).Render()

If you still facing issue, Please share the simple sample.  That will be helpful for us to recreate the same in our side and provide you the solution at the earliest. 

Regards,
Suriya M.

Loader.
Up arrow icon