xforms-readonlyAdded by IBM on October 10, 2012 | Version 1 (Original)
|Occurs when a data node is read-write (readonly = false) becomes readonly, or when a node that is readonly changes value and remains readonly.
This event is triggered on the XForms control bound to that node.
Available In xforms:input, xforms:output, xforms:range, xforms:secret, xforms:select, xforms:select1, xforms:submit, xforms:textarea, xforms:trigger, xforms:upload
Example This example shows a field item that accepts the first name of the user's spouse. When the user selects the "married" radio button, this field becomes read-write. If the user then select "single", the field becomes readonly and the xforms-readonly event is triggered. In this case, the event triggers the xforms:message action, which tells the user that the spousal information is not required.
The following bind sets makes the spouse's name readonly if the "single" radio button is selected:
The following code defines the label that collects the spouse's first name:
<xforms:bind nodeset="personalInfo/spouseFirstName" readonly="../single = 'on'"/>
<xforms:label>Spouse's First Name:</xforms:label>
level="modal">Spousal information is not required.</xforms:message>
- The order in which user interface events are processed is indeterminate. This means you cannot rely on them processing in a particular order.