Error on resuming calc service that has a custom name that refers deleted sheet

Posted by: ffrey on 12 December 2019, 9:59 am EST

    • Post Options:
    • Link

    Posted 12 December 2019, 9:59 am EST

    Good morning,

    we are migrating a product we have develop from spreadjs version 11 to version 12 and we found that one specific scenario is not working correctly for us in v12 but was working ok in v11.

    Scenario for reproducing the error is as follows:

    1. Define 2 worksheets in a spread, Sheet1 and Sheet2
    2. Define a custom name “customName1” in Sheet2 for a cell “B2”
    3. Set a formula in Sheet1 that refers to “customName1”
    4. Call suspendCalcService for the entire spread.
    5. Remove Sheet2.
    6. Call resumeCalcService and a JS error will occur.

    Side note: notice that in v12 the “customName1” expression is evaluated as “=#REF!” and in v11 is “=Sheet2!$B$2”.

    I have created some example with the instructions in the attached .zip file for both versions and as I said v11 is working fine but v12 crashes. Can you please take a look and let me know if there’s anything I’m doing wrong or if it’s a bug in spreadjs12?

    Also I’d like to know if there could be a workaround for that.

    Thanks,

    Fernandospreadjs issue.zip

  • Posted 13 December 2019, 1:22 am EST

    Hi Fernando,

    The issue is already fixed in the v13 version. You may confirm the same using the following sample:

    https://codesandbox.io/s/spread-js-starter-e18ci

    Please update to the latest version and let us know if the issue persists for you.

    Side note: notice that in v12 the “customName1” expression is evaluated as “=#REF!” and in v11 is “=Sheet2!$B$2”.

    This is by design, since the Sheet2 is deleted, the customer range can no longer refer to the Sheet2 hence the REF error.

    Regards

    Sharad

  • Posted 13 December 2019, 10:43 am EST

    Gotcha, thank you for your quick response.

    Regards,

    Fernando

Need extra support?

Upgrade your support plan and get personal unlimited phone support with our customer engagement team

Learn More

Forum Channels