Workbook rightToLeft exception - Can't open files from OpenXML-SDK, ClosedXML

Posted by: kamil.skrouba on 29 November 2024, 5:17 am EST

    • Post Options:
    • Link

    Posted 29 November 2024, 5:17 am EST - Updated 29 November 2024, 6:31 am EST

    Hi,

    After upgrading wijmo from version 5.20231.904 to 5.20241.19, we are encountering issues with Workbook Class. There is no way to open XLSX file created by OpenXML SDK or ClosedXML libraries.

    Error code:

    TypeError: Cannot set properties of undefined (setting 'rightToLeft')
        at _xlsx._getSheet (es5-esm.js:14:55720)
        at es5-esm.js:14:39222
        at _ZoneDelegate.invoke (zone.js:369:28)
        at Object.onInvoke (core.mjs:7248:33)
        at _ZoneDelegate.invoke (zone.js:368:34)
        at ZoneImpl.run (zone.js:111:43)
        at zone.js:2538:40
        at _ZoneDelegate.invokeTask (zone.js:402:33)
        at core.mjs:6913:55
        at AsyncStackTaggingZoneSpec.onInvokeTask (core.mjs:6913:36)

    I don’t know if it’s related but if you open these files and save it in Microsoft Excel then the Workbook can open these files.

    Files:

    Excel Files.zip

    Here is the example code:

    https://developer.mescius.com/wijmo/demos/Excel/WorkbookViewer/angular

  • Posted 29 November 2024, 7:41 am EST

    Hi Kamil,

    Unfortunately, Loading Excel files created using Tools other than Microsoft Excel is not currently support in Wijmo.

    The document structure and attributes used in files you have shared is different from what Excel uses.

  • Posted 29 November 2024, 8:07 am EST - Updated 29 November 2024, 8:32 am EST

    Hi Akshay,

    Can you tell me what is missing?

    Also I want to mention that in previous version it was supported.

  • Posted 2 December 2024, 3:26 am EST

    Hi Kamil,

    >> Can you tell me what is missing?

    As I mentioned earlier the documents created with Open XML SDK Closed XML Libraries have different document structure and tags when compared to the Excels created with Microsoft Excel. Currently, we do not support Excel files created using Tools other than Microsoft Excel.

    >> Also I want to mention that in previous version it was supported.

    I tested this at my end and I wasn’t able to reproduce this issue at my end. I tested this with the following sample application: https://stackblitz.com/edit/js-7scxsn?file=index.js

    For testing, I load the Excel file you have shared and and tried to import it in the FlexGrid. Although, no error is thrown in v5.20231.904, the file is not loaded.

    If you are able to import the file in v5.20231.904, please share a sample application reproducing this behavior or edit the attached sample such that it reproduces this behavior so we can look into it and get back to you accordingly.

Need extra support?

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

Learn More

Forum Channels