Could not load Sfdt data send via server (ASP .Net core) using documenteditor.open() in React

Hello team,

I am converting the sfdt data  into docx format in server (asp.net core)  which is sent from the front end(react). then I again convert the data in docx format into sfdt in purpose of send back to front end. 

here I am having a problem when loading that sfdt data using documenteditor.open();  it is firing an error as follows.

word issue 02 _01.png


3 Replies

SM Suriya Murugan Syncfusion Team March 15, 2022 07:53 AM UTC

Hi Pasindu,


Please check below documentation for reference:


https://ej2.syncfusion.com/react/documentation/document-editor/how-to/open-default-document/#opening-a-default-document-in-documenteditorcontainer


If you get JSON object, please use JSON.stringify to before send to open in document editor.

container.documentEditor.open(JSON.stringify(//data));


Please share the SFDT if you still facing the same issue.


Regards,

Suriya M.



PO pasindu osadha March 15, 2022 03:49 PM UTC

this method also not working.  i have attached the sfdt file along with this reply.

note : i am using typescript with react. 


Attachment: sfdt_word_d1e9743d.zip


SM Suriya Murugan Syncfusion Team March 17, 2022 07:49 AM UTC

Hi Pasindu,


Please check below sample for reference in which we have loaded provided JSON and it loaded without any issue:


https://stackblitz.com/edit/react-nsmqss


Please let us know if you still facing issue.


Regards,

Suriya M.


Loader.
Up arrow icon