SpliceMethodWizard.CurrentState

Syntax

CurrentState: Object

Description

The CurrentState property contains current settings of the wizard for time series splicing.

Comments

Use the setCurrentState method to set the property value, and the getCurrentState method to get the property value. Property value cannot be set from JSON.

This property contains a JSON object with the following fields: dependentSeries - array of dependent series, direction - series splicing direction (this value is defined with an element of the PP.TS.Ui.TsSpliceDirection enumeration), selectionTimeRanges - array of selected time ranges, splice - settings of series splicing (this object contains the direction and type properties),  type - method of series splicing (this value is set using the PP.TS.Ui.TsSpliceType enumeration).

Example

To execute the example, the HTML page must contain the WorkbookBox component named workbookBox (see Example of Creating the WorkbookBox Component). Set method and direction of time series splicing in an appropriate wizard in the Parameters tab of the workbook side panel:

// Get workbook properties panel
var propertyBar = workbookBox.getPropertyBarView();
// Get parameters panel
var parametersPanel = propertyBar.getParametersPanel();
// Display panel
parametersPanel.show();
// Expand panel
parametersPanel.expand();
// Get time series splice wizard 
var spliceMethodWizard = parametersPanel._SpliceMethodWizard;
// Display wizard 
spliceMethodWizard.show();
// Get wizard settings 
var state = spliceMethodWizard.getCurrentState();
// Set series to growth rate splice method
state.type = PP.TS.Ui.TsSpliceType.Pch;
// Set the Backward series splice direction type
state.direction = PP.TS.Ui.TsSpliceDirection.Backward;
// Determine new wizard settings
spliceMethodWizard.setCurrentState(state);

After executing the example the method of series splicing with inverse growth rates is selected in the time series splicing wizard:

See also:

SpliceMethodWizard