Complex format is not supported with the doc file be created by WPS Office app

Hi there,

I have a doc file (test file - save_as_wps.doc) be created by the WPS Office app that syncfusion can't read the file and throw exception: 

System.NotImplementedException: Complex format is not supported

   at Syncfusion.DocIO.ReaderWriter.WordReader.ReadDocumentHeader (Syncfusion.DocIO.Portable, Version=20.1200.0.58, Culture=neutral, PublicKeyToken=3d67ed1f87d44c89)

   at Syncfusion.DocIO.DLS.DocReaderAdapter.Read (Syncfusion.DocIO.Portable, Version=20.1200.0.58, Culture=neutral, PublicKeyToken=3d67ed1f87d44c89)

   at Syncfusion.DocIO.DLS.WordDocument.OpenInternal (Syncfusion.DocIO.Portable, Version=20.1200.0.58, Culture=neutral, PublicKeyToken=3d67ed1f87d44c89)

   at Syncfusion.DocIO.DLS.WordDocument.Open (Syncfusion.DocIO.Portable, Version=20.1200.0.58, Culture=neutral, PublicKeyToken=3d67ed1f87d44c89)


If I save as this file by Microsoft Office 365 app, syncfusion works fine (test file - save_as_ms.doc). Please help me to review these files (please refer to the attachment).

issue_with_wps.png


Many thanks,

Tuong.


Attachment: issue_with_wps_ec728663.zip

2 Replies 1 reply marked as answer

SB Suriya Balamurugan Syncfusion Team June 6, 2022 03:33 PM UTC

Hi Tuong,

On further validating the reported issue, we have found that the given document (test file - save_as_wps.doc) containing incremental save information.

Essential DocIO process the content that are preserved in the last complete save operation alone from a Word (.doc) document and it doesn’t process the incremental save information. Hence it throws “Complex format is not supported” exception when attempting to open a Word (.doc) document containing incremental save information.

To open a Word (*.doc) document containing incremental save information without exception, we suggest you to use SkipIncrementalSaveValidation API value as true before opening a Word document.

For more information and code example, please refer the below link.
https://help.syncfusion.com/file-formats/docio/word-file-formats#open-a-word-doc-document-containing-incremental-save-information

Regards,
Suriya Balamurugan.


Marked as answer

TH Tuong Huynh June 15, 2022 04:04 AM UTC

Hi Suriya Balamurugan,


I use SkipIncrementalSaveValidation as you suggest, and it works fine.


Many thanks,

Tuong.


Loader.
Up arrow icon