I’m using the Check Box Group control (xp:checkBoxGroup) as in the example on the wiki, using a dynamic lookup to get the values for the checkbox. In this scenario, I’m using values defined in a Notes document. Also defined in the Notes document are the default values.
One thing not covered there is how to set the selected values. I see there is a selectedValues property, but when I click on the plus icon, I get a greyed out “No items found” message. I’ve tried adding a selectedValues property in the source, but cannot work out how to get multiple checkboxes selected. With the code below, I get an error saying that selectedValues cannot be a run time binding.
<xp:checkBoxGroup id="response" value="#{ansDoc.response}">
<xp:this.selectedValues><![CDATA[#{javascript:@Explode(ansDoc.getItemValue("Default"), ",")}]]></xp:this.selectedValues>
<xp:selectItems>
<xp:this.value><![CDATA[#{javascript:ansDoc.getItemValue("aChoices")}]]></xp:this.value>
</xp:selectItems>
</xp:checkBoxGroup>
With a single hardcoded checkbox I can set the defaultChecked property, but there is not an option with the xp:selectItems group.
There is nothing in the Help about checkBoxGroups, it’s not accessible from the Core Controls, it’s not in any of the inbuilt templates, the only information on it is the article in the wiki, so it seems like it was later development to implement dojo controls. Is it even possible to define multiple default checkboxes as checked when creating a dynamic check box group?
If not, will it be available in 8.5.1?
Thanks
Paul Withers