Workbook Styles not exported in JSON

Posted by: matthias.hauser on 9 March 2022, 12:56 am EST

  • Posted 9 March 2022, 12:56 am EST

    Dear Support

    Can you tell me, why this simple test case doesn’t pass?

    
    Workbook workbook = new Workbook();
    
    IStyle thinStyle = workbook.getStyles().add("thin");
    thinStyle.getBorders().setLineStyle(BorderLineStyle.Thin);
    
    String json = workbook.toJson();
    
    assertThat(json).contains("thin");
    
    

    The reason I would need this is as follows: a SpreadJS is created from the JSON in the client. Depending on the user input, a corresponding style should then be set, but this does not work because the style is not exported at all.

    Is there a way that the style is also exported, although it is not (yet) explicitly used?

    Best regards

    Matthias

  • Posted 9 March 2022, 6:01 pm EST

    Hello,

    This has been replied to on your support case.

    https://www.grapecity.com/my-account/my-support/case/4a8c4aa6-b19f-ec11-b400-000d3a99e4a2

    Please continue the thread there only to avoid confusion.

    Regards,

    Prabhat Sharma.

  • Posted 9 March 2022, 6:05 pm EST

    Hi Prabhat

    Sorry for that. I tried to create this forum post yesterday and faced problems saying my post contains “spam”. The post didn’t seem to be published, so I then created the mentioned support case.

    Reagrds,

    Matthias

  • Posted 13 March 2022, 11:12 pm EST

    Hello Matthias,

    Apologies for the inconvenience caused. Please continue the thread there only for this case.

    Also let us know if you again such issue when creating a forum post.

    Regards,

    Prabhat Sharma.

Need extra support?

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

Learn More

Forum Channels