Skip to content

Formulae not retained on export #152

@ghost

Description

When a worksheet has cells with valid .f properties (formula), the value is not retained during exporting to XLSX format via:

var workbook = workbook = Xlsx.readFile('OnDemand.xlsx', { 
    cellFormula: true, 
    cellStyles: true, 
    sheetStubs: true, 
    cellNF: true, 
    bookDeps: true 
});
var out = Xlsx.write( workbook, { bookType: 'xlsx', /*bookSST: true,*/ type: 'binary' });

I need to support such functionality for the modification of templated workbooks. For example, the template has a cell, Q16 with the formula =IF(ISERROR((N16*M16*R16)/101.8),0,((N16*M16*R16)/101.8)). When output via the above code, the value "0" is produced instead.

No formula information is retained, and the cell is a "General" cell of value "0". Is there a workaround or solution to this?

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