How to parse SJS file?

Posted by: marcio.shimoda on 27 January 2023, 9:42 am EST

    • Post Options:
    • Link

    Posted 27 January 2023, 9:42 am EST

    Hi!

    I’m using SpreadJS on the frontend to create spreadsheets, but there are some situations where I have to generate the spreadsheets on the backend and open them on the frontend.

    Is there any API or documentation to help me handle the SJS file in the backend?

  • Posted 27 January 2023, 9:58 am EST

    I dont think you will be able to create a SJS file on the server side.

    SJS seems to use internally so called typedArrays - which is a kind o binary stream.

    And I dont think that GrapeCity are going to provide any detail about the internally structure of this “stream.”

    Also: It make no sense at all … to me …

    But that´s my assumption!

    So finally I am pretty sure that your design is wrong.

    Re-think why there is a need to implement it as you described it!

    Think about alternatives - like:

    The SpreadJS can fully designed/createdmanipulated/ on client side.

    There are hundreds of client side (javascript/ ts / …) methods to handle every thing you can imagine! I never ever run out of out-of-the-box available methods provided by GrapeCity!

    So think about to “move” your sever side logic to the client.

    Communicate via api calls to send data back and forwards …

    I am sure there is min. one solution for your requirements already in the set of GrapeCity methods …

  • Posted 27 January 2023, 10:18 am EST

    Hi @uraatz!

    Thanks for the sugestions!

    We already use the archtecture you described. But using that approach, sometimes we get responses of more than 54 MB and using SJS we got 300 KB max.

  • Posted 27 January 2023, 10:29 am EST

    WOW!

    300 KB are only around 0.555% from 54 MB (= 54,000 KB).

    So the SJS compression rate is around 99.444%.

    Sorry no further idea :frowning:

Need extra support?

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

Learn More

Forum Channels