W3C home > Mailing lists > Public > www-forms@w3.org > June 2003

RE: switch toggles conditional on XPath expressions?

From: Jeremy Johnson <jeremy.johnson@imtc.gatech.edu>
Date: Wed, 11 Jun 2003 15:23:41 -0400
Message-ID: <F13878E3B91C864EA658C56CABCC00030F87@imtcmail.imtc.gatech.edu>
To: <www-forms@w3.org>
I've learned that an XForms user interface will commonly render a form
control bound to a data item only if the 'relevant' property of the data
item is true, thus producing the effect on form controls that I desire.
-----Original Message-----
From: Jeremy Johnson 
Sent: Wednesday, June 11, 2003 2:50 PM
To: www-forms@w3.org
Subject: switch toggles conditional on XPath expressions?
I'm a complete XForms novice, so please forgive me if I am missing
something considered "obvious".
I would like to toggle a switch based on the evaluation of an XPath
boolean expression, but I don't see a construct of XForms mechanisms
that can accomplishing such.
The effect I'm trying to achieve is this:  I want form controls to only
be visible when an arbitrary XPath boolean expression evaluates to true,
analogous to the "readonly" property that may be applied to model items,
however I want to ensure that an associated form control does not appear
on screen at all, not simply rendered disabled.  These controls would
appear / disappear as items in the data model take on new values.
My original thought was to surround each control with a <switch> element
and have an action respond to all value changes which would
conditionally (based on an XPath expression) toggle each control to
"appear" or "disappear".  Unfortunately, I'm unsure of a way to achieve
the conditional toggle.
Is there another way to accomplish such an effect?
Any suggestions would be most welcome.
  .: jeremy.johnson@imtc.gatech.edu :.
.: interactive.media.technology.center :.
  .: georgia.institute.of.technology :.
Received on Wednesday, 11 June 2003 15:26:37 UTC

This archive was generated by hypermail 2.3.1 : Tuesday, 6 January 2015 21:36:08 UTC