PSWriteWord icon indicating copy to clipboard operation
PSWriteWord copied to clipboard

Merge-WordDocument on documents with WordCustomProperties leads to unreadable error

Open drtyhlpr opened this issue 4 years ago • 0 comments

Thanks for your great script!

I have created two word documents with custom word properties. If I merge the documents with Merge-WordDocument no errors occur but if I try to open the generated output document I get a Word error: "Word found unreadable content in xxx.docx. Do you want to recover the contents of this document?". The recovery works fine but the fixed document is quite strange:

The recovered (output) document only seems to contain the WordCustomProperties of the 1st Document BUT I can see the (merged) WordCustomProperties of the 2nd Document as fully working Fields (even the toggle field code looks fine) but the WordCustomProperties of the 2nd Document are definitely not listed in the (recovered output) document's custom word properties....

if you need further information or code please tell me. I am doing some tests with adding the 2nd document's WordCustomProperties manualy to the 1st document etc.

drtyhlpr avatar May 05 '21 12:05 drtyhlpr