We have updated Flexmonster Software License Agreement, effective as of September 30, 2024. Learn more about what’s changed.
All documentation
  • API Reference for older versions
  • openCalculatedValueEditor

    openCalculatedValueEditor(uniqueName: String, callbackHandler: Function)

    [starting from version: 2.7.9]

    Opens the calculated value pop-up window editor. Calling openCalculatedValueEditor results in opening an empty editor for creating a new value. It is also possible to open this editor for editing or deleting an existing calculated value.

    Parameters

    Parameter/TypeDescription
    uniqueName
    String
    optional The unique name of the calculated value. It is used for editing or deleting an existing calculated value.
    callbackHandler
    Function
    optional Called after a particular action (clicking the Apply or Delete button). It has the following parameter:
    • response - ResponseObject. Contains information about the changed calculated value.

    ResponseObject

    Property/TypeDescription
    uniqueName
    String
    The unique name of the calculated value.
    isRemoved
    Boolean
    Specifies whether the calculated value was removed (true) or not (false).

    Examples

    1) How to open the calculated value editor without parameters:

    pivot.openCalculatedValueEditor();

    Check out on JSFiddle.

    2) How to open the calculated value editor for the previously defined calculated value (Revenue):

    pivot.openCalculatedValueEditor("Revenue");

    Check out on JSFiddle.

    3) How to open the calculated value editor for the previously defined calculated value (Revenue) and send a function as a callback:

    pivot.openCalculatedValueEditor("Revenue", function(response) {
    console.log(response);
    });

    Check out on JSFiddle.

    See also

    Calculated values tutorial
    addCalculatedMeasure
    getAllMeasures
    getMeasures
    removeAllCalculatedMeasures
    removeCalculatedMeasure