Use APIs Related to BPC Planning Sequence

As an application designer, after adding a BPC Planning Sequence widget, you can use related APIs to let application users run the planning sequence without manually setting any variable values and do various operations on the variable values of planning functions at runtime.

You can add a BPC Planning Sequence widget to let application users run a planning sequence with one or more planning functions with BPC live data connection.

Then, you can use a combination of related APIs to offer application users more options to interact with it. For example, they can run a planning sequence with the pre-defined variable values and modify the values at runtime as well.

Note

As BPC live data connection isn't supported for mobiles, the related APIs aren't supported as well.

You can use the following variable related APIs on data source level for setting, getting, removing and copying the variable values of a planning sequence:
Code Syntax
//Sets the variable values of a planning sequence.
BpcPlanningSequence.getBpcPlanningSequenceDataSource().setVariableValue(variable: string | VariableInfo, variableValue: string | number | VariableValue JSON | VariableValue[] JSON, options?: SetVariableValueOptions JSON): void
//Gets the variable values of a planning sequence.
BpcPlanningSequence.getBpcPlanningSequenceDataSource().getVariableValues(variable: string | VariableInfo): VariableValue[];
//Gets all variables of a planning sequence.
BpcPlanningSequence.getBpcPlanningSequenceDataSource().getVariables(): VariableInfo[];
//Removes variable values from a planning sequence.
BpcPlanningSequence.getBpcPlanningSequenceDataSource().removeVariableValue(variable: string | VariableInfo): void
//Copies variable values of a planning sequence.
BpcPlanningSequence.getBpcPlanningSequenceDataSource().copyVariableValueFrom(sourceDataSource: DataSource, variable?: string | string[] | VariableInfo | VariableInfo[]): void
The following API is for running a planning sequence:
Code Syntax
BpcPlanningSequence.execute(): BpcPlanningSequenceExecutionResponse;
The following API is for opening the prompt dialog where application users can modify the variables:
Code Syntax
BpcPlanningSequence.openPromptDialog();