Skip to content

.commit() method breaks some formulas #20

@urpizu

Description

@urpizu

Being a formula in a random cell: =SUM($1:$2) / =SUM($A:$B)
After commit it's broken to: =SUM(R1:R2) / =SUM(C1:C2)

After some research, it's a Google Sheets API issue. While next methods are equivalent...
range.setValue(=R[0]) ~= range.setFormulaR1C1(=R[0])

It looks that .setValue() can not recognize next R1C1 pattern, when .setFormulaR1C1() can:
range.setValue(=R1:R2) !== range.setFormulaR1C1(=R1:R2)

I've been able to avoid the issue using the Item.commitFieldValue(field) method.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions