Page 1 of 1

Failed to Parse - Word content issue

Posted: Wed Jun 26, 2024 7:49 pm
by Stacey
Hi There:
I watched the Integrating Various Document Formats (OpenAPI, Word, Markdown, HTML, Excel) into DITA Documentation webinar and am trying out including Word docs in content.
I get an error message when I'm trying to include a bookmarked Word paragraph in output: [DOTJ013E] Failed to parse the referenced file ... Content is not allowed in prolog.
I can clear this error message by adding format="word-to-dita" to the <p> tag in oXygen, but then I get a validation message: Attribute "format" is not allowed to appear in element "p".
oXygen still lets me publish and things seem okay, so am I supposed to ignore this message? Or should I be able to include the <p> reference (it includes a conref) without adding "format" (which in the webinar is required for xrefs, etc.)?
Thanks,

Re: Failed to Parse - Word content issue

Posted: Thu Jun 27, 2024 6:16 am
by Radu
Hi Stacey,
What version of Oxygen are you using? Are you using for publishing its bundled DITA OT publishing engine or a custom publishing engine? Did you install extra plugins in the DITA OT?
Our sample DITA map from "OXYGEN_INSTALL_DIR/samples/dita-dynamic-conversions/word/map.ditamap" has a sample topic.dita with a conref like this:

Code: Select all

<p conref="wordToReuse.docx#word_document_to_reuse_content_from_it./para_bookmark"/>
Running the publishing to plain HTML5 I do not seem to get any error pertaining to it's use, the conref resolves.
Regards,
Radu

Re: Failed to Parse - Word content issue

Posted: Thu Jun 27, 2024 4:34 pm
by Stacey
Hi Radu:
Thank you! The sample files were really helpful.
I'm currently using XML Editor 26.1, build 2024031806
It took a lot more poking around to "figure" things out.
It looks like the main problem is the fix.external.refs.com.oxygenxml parameter - when true the referenced content is not included (unless the format="word-to-dita" was added to the referenced <p> element); when false, it is included.
I forget what problem we were trying to solve by updating our scenario to true for that parameter, so I guess this'll work for now. :)

Re: Failed to Parse - Word content issue

Posted: Mon Jul 01, 2024 7:19 am
by Radu
Hi Stacey,
Good observation about the "fix.external.refs" interfering with this functionality, I reproduced the problem and added an internal issue to look into fixing it for a future version, pasting the internal issue ID below for future reference:
EXM-54598 Fix external references does not work well with conrefs inside Word documents

Usually people end up enabling the "fix.external.refs.com.oxygenxml" transformation parameter to support cases like this:
https://www.oxygenxml.com/doc/versions/ ... -refs.html

Regards,
Radu

Re: Failed to Parse - Word content issue

Posted: Thu Nov 28, 2024 12:50 pm
by Radu
Hi,
As an update we released Oxygen 27 yesterday which should have a fix for the problem reported above.
Regards,
Radu

Re: Failed to Parse - Word content issue

Posted: Mon Dec 02, 2024 5:17 pm
by Stacey
Okay. Thanks!