Validation error when trying to insert a section into a general task(body)

doctissimus
Posts: 8
Joined: Tue Mar 03, 2020 11:15 pm

Validation error when trying to insert a section into a general task(body)

Post by doctissimus » Tue Mar 03, 2020 11:49 pm

Hi,

I am using Oxygen 22. I created a General Task file that generated a skeleton topic with the following declaration.

Code: Select all

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE task PUBLIC "-//OASIS//DTD DITA General Task//EN" "generalTask.dtd">
Here is some pseudo-markup of the topic I'm trying to create:

Code: Select all

<task>
  <taskbody>
    <steps>
      ...
    </steps>
    <section>
      ...
    </section>
  </taskbody>
</task>
From what I can tell (http://docs.oasis-open.org/dita/dita/v1 ... s__section and http://docs.oasis-open.org/dita/v1.2/os ... ction.html), a section is allowed within a taskbody - but I'm getting a validation error from Oxygen.

Any insight is appreciated.

Thanks,

doctissimus

april_m
Posts: 9
Joined: Mon Oct 21, 2019 10:55 pm

Re: Validation error when trying to insert a section into a general task(body)

Post by april_m » Wed Mar 04, 2020 12:05 am

You want to use <stepsection> in a task. It is different from a regular <section> in that it acts more like a break between steps, not a container for steps. If you want to contain some steps beneath a parent step, use <substeps>. Also, you cannot end a task on <stepsection>; <stepsection> must be followed by <steps>. To add information at the end of a task, use <result> or <postreq>.

https://www.oxygenxml.com/dita/1.3/spec ... ction.html

Radu
Posts: 6922
Joined: Fri Jul 09, 2004 5:18 pm

Re: Validation error when trying to insert a section into a general task(body)

Post by Radu » Wed Mar 04, 2020 10:57 am

Hi,

According to the DITA schemas you can have a section in a general task but it must appear before the context and steps.
So something like this is valid:

Code: Select all

<!DOCTYPE task PUBLIC "-//OASIS//DTD DITA General Task//EN" "generalTask.dtd">
<task id="task_v2p_zzn_xkb">
    <title></title>
    <shortdesc></shortdesc>
    <taskbody>
        <section id="section_q3l_114_xkb">
            <title/>
            <p/>
        </section>
        <context>
            <p></p>
        </context>
        <steps>
            <step>
                <cmd></cmd>
            </step>
        </steps>
    </taskbody>
</task>
but you cannot insert it after the steps.

Regards,
Radu
Radu Coravu
<oXygen/> XML Editor
http://www.oxygenxml.com

doctissimus
Posts: 8
Joined: Tue Mar 03, 2020 11:15 pm

Re: Validation error when trying to insert a section into a general task(body)

Post by doctissimus » Wed Mar 04, 2020 11:32 pm

Hi april_m and Radu,

Thanks very much for the great information, I appreciate your generosity as I climb this learning curve. I am hoping to place some supplemental information after the task steps, so I am going to try a potreq or a resuslts element.

Thanks, again.

doctissumus

Post Reply