Page 1 of 1

Constrain the values of an attribute based on the value of another attribute

Posted: Wed Aug 08, 2018 11:00 pm
by rjcbop
We have what I understand is a co-occurrence constraint where we want the allowed values of a particular attribute, say B, to be constrained based on the specified value of another attribute, say A. Is there some way to embed this constraint in the authoring environment such that you have pick lists for A and B, and where the available values of B depend on what's selected for A? For reference, we tried to do this through a subject scheme but were not successful.

Re: Constrain the values of an attribute based on the value of another attribute

Posted: Thu Aug 09, 2018 7:26 am
by Radu
Hi,

Indeed having this possibility through a Subject Scheme map would have been cool. Especially that Oxygen uses Subject Scheme maps also for validation and would have flagged such problems. But Subject Scheme maps do not have the mechanism to express this.
We do have a content completion configuration file which can call an XSLT extension to achieve what you want, there is a blog post by my colleague Alex about this:

http://blog.oxygenxml.com/2015/07/contr ... art-2.html

Regards,
Radu

Re: Constrain the values of an attribute based on the value of another attribute

Posted: Thu Aug 09, 2018 3:43 pm
by rjcbop
Thank you!