I have a data field that represents a bunch of checkboxes, which is stored as a series of bits in a number variable.
Checkbox1 = bit 1
Checkbox2 = bit 2
if (value && 1)
if (value && 2)
<xsl:when test="$datavalue and @BitMask != 0">
... always returns 'true', because XSL seems to simply test for the existence of the variable or attribute, so instead of '$datavalue and @BitMask != 0' being calculated as (for example) '35 and 4', which should be zero, it calculates it as "true and true" because both the $datavalue variable and @BitMask attribute exist.
Is there any way to do a bitwise operation in XSL?