Uploaded image for project: 'ZK Spreadsheet'
  1. ZK Spreadsheet
  2. ZSS-575

Cannot edit a formula with non-existed named range

XMLWordPrintable

      Reproducing Steps:

      1. Run Spreadsheet and load an Excel 2003 file (zss.test/display2003.zul)
      2. enter =sum(d) in a cell
      3. edit the same cell

      Actually See:
      IllegalStateException is thrown.

      2014/3/4 上午 09:19:34 org.zkoss.zk.ui.impl.UiEngineImpl handleError:1352
      嚴重的: >>java.lang.IllegalStateException: Too few arguments supplied to operation. Expected (2) operands but got (0)
      >> at org.zkoss.poi.ss.formula.FormulaRenderer.getOperands(FormulaRenderer.java:125)
      >> at org.zkoss.poi.ss.formula.FormulaRenderer.toFormulaString(FormulaRenderer.java:101)
      >> at org.zkoss.poi.hssf.model.HSSFFormulaParser.toFormulaString(HSSFFormulaParser.java:83)
      >> at org.zkoss.poi.hssf.usermodel.HSSFCell.getCellFormula(HSSFCell.java:624)
      >> at org.zkoss.zss.model.impl.BookHelper.getEditText(BookHelper.java:993)
      >> at org.zkoss.zss.model.impl.BookHelper.getRichEditText(BookHelper.java:1052)
      >> at org.zkoss.zss.model.impl.RangeImpl.getRichEditText(RangeImpl.java:287)
      >> at org.zkoss.zss.ui.impl.Utils.getRichEditText(Utils.java:924)
      >> at org.zkoss.zss.ui.impl.Utils.getEditText(Utils.java:891)
      >> at org.zkoss.zss.ui.fn.UtilFns.getEdittext(UtilFns.java:115)
      >> at org.zkoss.zss.ui.Spreadsheet$ExtraCtrl.getCellAttr(Spreadsheet.java:3110)
      >> at org.zkoss.zss.ui.Spreadsheet$ExtraCtrl.getRangeAttrs(Spreadsheet.java:2933)
      >> at org.zkoss.zss.ui.Spreadsheet.responseUpdateCell(Spreadsheet.java:2557)
      >> at org.zkoss.zss.ui.Spreadsheet.updateCell(Spreadsheet.java:2526)
      >> at org.zkoss.zss.ui.Spreadsheet.access$13(Spreadsheet.java:2479)
      >> at org.zkoss.zss.ui.Spreadsheet$InnerDataListener.onContentChange(Spreadsheet.java:2240)
      >> at org.zkoss.zss.ui.Spreadsheet$InnerDataListener.access$6(Spreadsheet.java:2232)
      >> at org.zkoss.zss.ui.Spreadsheet$InnerDataListener$7.onEvent(Spreadsheet.java:2032)
      >> at org.zkoss.zss.engine.event.EventDispatchListener.onEvent(EventDispatchListener.java:43)
      >> at org.zkoss.zssex.engine.impl.RefBookImpl$DelegateListener.onEvent(RefBookImpl.java:110)
      >> at org.zkoss.zk.ui.event.impl.DesktopEventQueue$QueueListener.onEvent(DesktopEventQueue.java:145)
      >> at org.zkoss.zk.ui.AbstractComponent.onEvent(AbstractComponent.java:2732)
      >> at org.zkoss.zk.ui.AbstractComponent.service(AbstractComponent.java:2703)
      >> at org.zkoss.zk.ui.AbstractComponent.service(AbstractComponent.java:2644)

            hawk hawk
            hawk hawk
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved: