Create a Ditaval file

You use the DITA CMS Ditaval view to create conditional processing profiles for your documents. Each profile that you create is stored in a .ditaval file.

A Ditaval file is created by specifying the conditions to exclude and to include when generating the output for a document. By default in the DITA open toolkit (DITA-OT), if a condition is not specified in the Ditaval file, then it is automatically included in the generated output. To exclude a condition, you must explicitly configure it as such in the Ditaval file. Any condition that is not explicitly excluded is included in the output.

When you create a Ditaval file in the Ditaval view, you can define the Default action as include, exclude, passthrough, or flag. For example, if you set the Default action to "exclude", then you would only need to specify the ones that you want to include.

To create a Ditaval file:

  1. Open the Ditaval view.
  2. Right-click the folder where to add the Ditaval file and select New Ditaval.
    The Create Ditaval dialog appears, which initially lists all the conditions that are defined in the DITA CMS configuration file. For example:
    Create Ditaval dialog
    Note: This dialog is customized per company. If the condition that you need to set in your Ditaval is not available, ask your DITA CMS administrator to add it to the DITA CMS configuration, as described in the DITA CMS Administrator's Guide or use a subject scheme.
  3. In the Title box, type a title for this Ditaval file.
    Note: This title is also used as the Ditaval file name. It must be unique.
  4. In the Description box, type a description (Optional).
  5. If you are creating a Ditaval file for a subject scheme, select the Use a Subject Scheme checkbox and click the subject scheme that you want from the list.
  6. If you want to define a default action, select the Default action checkbox and click the action that you want from the list.
  7. In the All conditions box, select the checkboxes for the conditions that you want in your Ditaval file.
  8. Click in the Action column and select the action that you want for each value:
    • Include: content is included in the output.
    • Exclude: content is excluded from the output.
    • Passthrough: content is included in the output and also retains the condition as part of the output.
    • Flag: content is included and marked in the output. By default no formatting of the condition is applied. Once the initial ditaval is created, you can edit the ditaval XML to add formatting attributes.
  9. Click OK.
    The new Ditaval file is created. You can now generate the output for a document using this Ditaval file.
  10. If you chose flag as an action for a condition, you can edit the ditaval to add the formatting attributes.
    1. Right-click the ditaval in the Ditaval view.
    2. Click Edit Ditaval XML.
    3. Find the instances of prop action="flag", add and set the color, backcolor, and style attributes as desired.
    4. Once you have completed your changes, save the file.
    5. Right-click the ditaval in the Ditaval view and click Release Ditaval XML.