visible

Defines whether or not the item is visible on the screen and can be printed.

Syntax

   <visible>status</visible>
Table 1. vusible parameter
Parameter Type Description
status on Item can be seen on the screen and printed
  off Item cannot be seen on the screen and will not print when the form is printed.

Available in

box, button, check, checkgroup, combobox, field, label, line, list, popup, radio, radiogroup, richtext, slider

Example

This sample shows how an item can be set to be visible at the user's request.

   <check sid="SHOW_INSTRUCTIONS">
      <value>off</value>
      <label>Do you want to see the instructions?</label>
   </check>
   <label sid="INSTRUCTION_LABEL">
      <visible compute="SHOW_INSTRUCTIONS.value=='on' ? &#xA;
         'on' : 'off'"></visible>
      <value>Please complete all portions of this form.</value>
   </label>

Usage details

  1. Default:
    • XFDL: on.
    • XForms: defaults to the relevant property for the data element to which the containing item is bound.
  2. An XFDL item in an xforms:group, xforms:repeat, or xforms:case will not be visible if:
    • The XFDL item containing the xforms:group, xforms:repeat, or xforms:case is not visible.
    • The xforms:case is not selected.
    • The row containing the XFDL item (created by the xforms:repeat) is non-relevant.

      These cases are true regardless of the visible option for that XFDL item, and regardless of whether the XFDL item itself contains XForms options.