selectValues method
Information noteSTABLE.
This API is reliable and breaking changes are unlikely.
This API is reliable and breaking changes are unlikely.
backendApi.selectValues(qDimNo, qValues, qToggleMode)
Selects values in this object with a Qlik associative engine call which triggers a repaint of the object.
Version history
Version state | Details |
---|---|
Introduced | 1.0 |
Parameters
qDimNo
Type: Number
Dimension number. 0 = first dimension.
qValues
Type: Array
Array of values (qElemNumber in the matrix from the Qlik associative engine) to select or deselect.
qToggleMode
Type: Boolean
If true, values in the field are selected in addition to any previously selected items.
If false, values in the field are selected while previously selected items are deselected.
Example
$element.find('li').on('click', function() {
if(this.hasAttribute("data-value")) {
var value = parseInt(this.getAttribute("data-value"), 10), dim = 0;
self.backendApi.selectValues(dim, [value], true);
}
});