RTC workitem making boolean attributes mandatory
![](http://jazz.net/_images/myphoto/a1964ea347c20a66892b93a1b98499d5.jpg)
Hi All,
Accepted answer
![](http://jazz.net/_images/myphoto/a1964ea347c20a66892b93a1b98499d5.jpg)
I suppose that the problem with making checkboxes mandatory is that they have always a value, i.e. "false" when they are not checked and "true" when they are.
Comments
![](http://jazz.net/_images/myphoto/a1964ea347c20a66892b93a1b98499d5.jpg)
Thanks for your response Luca.
![](http://jazz.net/_images/myphoto/e5e63d5878217b64611c1df9401b7cd3.jpg)
The presentation does not make a difference. A boolean value is always set and there is no unassigned. So mandatory does not make any sense for boolean attributes.
![](http://jazz.net/_images/myphoto/f4e752cc82358e242b98c2dbd9c9f052.jpg)
Use an enumeration attribute, maybe with just the "true" value.
This way, if the attribute is "unassigned" the mandatory condition will raise a validation error.
By explicitly setting it to "true", the condition will no longer raise any error.
![](http://jazz.net/_images/myphoto/a1964ea347c20a66892b93a1b98499d5.jpg)
Hello Luca,
![](http://jazz.net/_images/myphoto/f4e752cc82358e242b98c2dbd9c9f052.jpg)
Kunal,
when you define the enumeration for such an attribute, specify that the Unassigned" (or whatever string you like) value is set as both the Default Literal and the Unassigned Literal.
Then, you must set the attribute as mandatory in state "Y".
If the user who is moving the work item from X to Y has not set the attribute value to "True" the mandatory attributes precondition will raise a validation error.
1 vote
![](http://jazz.net/_images/myphoto/a1964ea347c20a66892b93a1b98499d5.jpg)
Thanks for your help Luca
One other answer
![](http://jazz.net/_images/myphoto/a1964ea347c20a66892b93a1b98499d5.jpg)
An alternative is use an enumeration with values "true" and "false". When you don't pick either value, the attribute is "unassigned".
Comments
![](http://jazz.net/_images/myphoto/a1964ea347c20a66892b93a1b98499d5.jpg)
Hi Donald,