poi-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bugzi...@apache.org
Subject [Bug 62216] New: SXSSFCell.setCellErrorValue turns a formula cell into an error cell, unlike XSSF
Date Fri, 23 Mar 2018 22:56:25 GMT
https://bz.apache.org/bugzilla/show_bug.cgi?id=62216

            Bug ID: 62216
           Summary: SXSSFCell.setCellErrorValue turns a formula cell into
                    an error cell, unlike XSSF
           Product: POI
           Version: 3.17-FINAL
          Hardware: PC
            Status: NEW
          Severity: normal
          Priority: P2
         Component: SXSSF
          Assignee: dev@poi.apache.org
          Reporter: gallon.fizik@gmail.com
  Target Milestone: ---

A fix for this seems to be a one-liner. In source

@Override
public void setCellErrorValue(byte value)
{
    ensureType(CellType.ERROR);
    if(_value.getType()==CellType.FORMULA)
        ((ErrorFormulaValue)_value).setPreEvaluatedValue(value);
    else
        ((ErrorValue)_value).setValue(value);
}


ensureType(CellType.ERROR);

is to be replaced by 

ensureTypeOrFormulaType(CellType.ERROR);

-- 
You are receiving this mail because:
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@poi.apache.org
For additional commands, e-mail: dev-help@poi.apache.org


Mime
View raw message