Open andregloeckner opened 1 month ago
Facing same issue
Hi @andregloeckner @Piyush-IT Thanks for reporting this issue. Seem I can repro, we'll take a look and report back if we have a suggestion for you.
Hi @shanshanzheng-dev,
do you already have an idea how to fix that? We cannot proced with the plugin idea we have, because with open we loose the context of which file it is. The context contain informations like, DocumentName, DocumentId, TemplateEntity, CurrentRevision and so on. Serializable to JSON.
So we have just the possiblity to open in current Word with staying in the document context we have. Or Call open with send an embedded json with the byte array to the new Word.
Best regards
@andregloeckner Thanks for reporting this. We have put on our backlog<Bug#9350173> for internal track. We found it happens for all insertfilefrombase64 apis and are still working on it. We will let you know if there are any updates.
Also, since this example is quite complex, I want to make sure we haven't missed anything. One content control should have included two rows but wrongly included all the table after inserting. Have you encountered similar problems with contentcontrols other than tables?
@Searion I asked my collegues about your questions and it looks like that all similar problems we encountered were related to the tables. Greetings
We create a lot of complexe document processing templates and have created a word addin which loads the files directly from our web application. It works well more or less...
But in some complexe edge cases we found problems by modified placeholders durring loading.
See: Correct version, can you achive by use Word->Document->Open with the file, or you use the follow code snipped.
The problem happens when you try to load the byte array content directly in the Current word session:
In the wrong case, you can see that the merge block is moved to a different position.
Your Environment
Expected behavior
We want to use the loading of a byte array in the same word window, the only methode I found is using the
Current behavior
Steps to reproduce
When open a docx file as byte[] to new Word with that code block, the format is fine.
When open a docx file as byte[] to current Word instance with that code block, it looks wrong.
Link to example(s)
Sample file well formated Extract.docx
Sample file after open with insertFileFromBase64() Extract - broken.docx