getCurrentState();
The getCurrentState method returns key and position of dimensions.
The method returns a JSON object that contains an array of objects with the fields k (dimension key) and position (dimension position defined using the PP.Exp.PvtDimPos enumeration).
Executing the example requires that the HTML page contains the ExpressBox component named expressBox (see Example of Creating the ExpressBox Component). Then refresh all dimensions in the panel and get the list of their keys:
var dimBar = expressBox.getPropertyBarView().getDimBarViewPanel(); // Display panel dimBar.show(); // Expand panel dimBar.expand(True); // Get array of dimensions var dims = dimBar.getCurrentState().dims.its.it; // Refresh all dimensions dimBar.refreshSelections(dims); // Output keyas of all dimension on panel var keys = ""; for(var i = 0; i < dims.length; i++) { keys += dims[i].k; keys += " "; }; console.log("Keys: " + keys);
After executing the example all dimensions in the panel are refreshed, and the browser console displays dimension keys:
Keys: 1646 2038 1824 2042
See also: