Word Generated after MS word Version update gives Word found unreadable content.

Since MS Word was update to Version 2404 Build 16.0.17531.20190, all the templates which we used with new version Word file is giving the below error

Word found unreadable content. Do you want to recover the contents of this of this document

All below methods gives the same issue

funtion - com.pegarules.generated.pega_appdefinition_documentapp.GenerateDocument(tmplName, tools,clssName,null);

Activity - pxGenerateWordDocument

pxGenerateAndAttachDocument

NO Code Change was done, and older MS Word Versions of Templates are working fine.

@Ishara Derek

We have the similar issue. Do we have a solution?

@Ishara Derek There is a hot fix need or pega platform upgrade.

@BhaskarG16982569 please see @JeevaAB 's reply below.

There is a Support Document which provides details of which hotfixes exist to remediate the problem:

Unreadable content error on opening documents generated from Microsoft Word templates

To apply the hotfix, you must be on Pega Platform 23.1.1.

Versions 8.8.3 and 8.8.4 should update to 23.1.1 and apply HFIX-B1455 to remediate the issue. We hope the fix will be integrated in the Pega 23.1.4 later this year.

@Ishara Derek I had the same issue and the only solution given by PEGA support is upgrade and apply a hotfix… That is too much for this issue.

So I figure out one solution.

Change the template extension from .docx to .zip then unzip the files and search for al the files containing w16du

They should be the following:

document.xml, endnotes.xml, fontTable.xml, footer1.xml, footer2.xml, footer3.xml, footnotes.xml, header1.xml, settings.xml, styles.xml, webSettings.xml

Update each one of them and delete the following:

xmlns:w16du="http://schemas.microsoft.com/office/word/2023/wordml/word16du

and delete w16du from this instruction

mc:Ignorable=“w14 w15 w16se w16cid w16 w16cex w16sdtdh w16du wp14”>

save the files and zip all of them again.

After that change back the extension to .docx again.

This fixed my issue.

NOTE: if you open and edit that file MS Word will add that code again so try to not edit before upload the template to PEGA .

Hope it helps.