• Resolved edjarrett

    (@edjarrett)


    I have created my first “book” and published it in a Microsoft Word format. Everything seems ok until I attempt to open the book. When I do, I get an error message that says Word is unable to open the file. It offers three suggestions

    1. check permissions – they are good
    2. make sure there is sufficient free memory and disk space – there is. It is only a small file.
    3. Try using the Text Recovery converter – it does not work either.

    Any ideas on how to proceed from here?

Viewing 9 replies - 1 through 9 (of 9 total)
  • Plugin Author ferranfg

    (@ferranfg)

    Have you tried checking the “Validate content before download” in the plugin settings? The plugin has a checkbox to validate the content before generating the book https://share.cleanshot.com/YUHwpL. It may be related.

    If no errors are found, try to refine your generation by choosing fewers posts until you find which post is responsible for corrupting the file.

    Thread Starter edjarrett

    (@edjarrett)

    Yes, Validate Content is checked, but, if it is giving any validation errors, I don’t see them anywhere.

    I did chooses fewer posts, and have found that there are a handful that are causing the error. I am at a loss to know why though. All the posts in the series are formatted identically. I edited one of them and updated it, but it made no difference.

    Plugin Author ferranfg

    (@ferranfg)

    Could you share with me the URL of both examples? (One of a post which is giving an error and one of a posts which is ok)

    If you prefer to do it privately, you can write me at [email protected])

    Thread Starter edjarrett

    (@edjarrett)

    Plugin Author ferranfg

    (@ferranfg)

    Thanks. Let me do a few checks and I will get back to you with my findings.

    Plugin Author ferranfg

    (@ferranfg)

    Hi @edjarrett

    I think I’ve found a reason. The error is due using & in your text. If you can confirm it, the pages that does not work should have a & and the others don’t.

    I will release a new version to address this issue in the coming days. Until then, if you have the chance to edit the PHP plugin’s code, you can add this line to fix the issue:

    https://github.com/ferranfg/mpl-publisher/blob/master/libs/WordPublisher.php#L44

    Thread Starter edjarrett

    (@edjarrett)

    Thanks. Removing the & from the one post did fix it. I will all that line of code in a little while. Thanks for your help on this.

    Thread Starter edjarrett

    (@edjarrett)

    I have added that line of code, and it seems to work well now. Thanks again.

    I did notice that the headings in my post become normal text in the Word document. Is that how it is supposed to work? It is not a big deal since I have to edit the file anyway to remove parts of the posts that are appropriate for a single post but not when they are combined into a single document.

    Plugin Author ferranfg

    (@ferranfg)

    Hi @edjarrett

    Glad it’s working. Thanks to you for your finding and patience.

    Regarding the heading, I’ve seen that new versions of the library the plugin uses internally to generate the Word document support appropriate headings, so I’m preparing a new plugin release to address this issue.

    Version 2.7 should support this feature. Most probably at the end of this week or the following.

Viewing 9 replies - 1 through 9 (of 9 total)
  • The topic ‘Error opening DOCX file’ is closed to new replies.