FlexGrid Group Row Style

Posted by: paul on 27 September 2019, 11:21 am EST

    • Post Options:
    • Link

    Posted 27 September 2019, 11:21 am EST

    Hi,

    When grouping by a column in FlexGrid, is it possible to apply a different style to the group row?

    Thanks

    Paul

  • Posted 30 September 2019, 4:56 am EST

    Hello,

    Yes, you can apply different styles on the Group row using CellStyle object from the C1FlexGridBase.Styles collection as per the node level.

    Here is the code snippet to set style for group row at level 0 :

    CellStyle s = _flex.Styles[CellStyleEnum.Subtotal0];
    s.BackColor = Color.Black;
    s.ForeColor = Color.White;
    s.Font = new Font(_flex.Font, FontStyle.Bold);
    

    You can set Styles up to Node level 5 as mentioned in the given link :

    https://help.grapecity.com/componentone/NetHelp/c1flexgrid/webframe.html#C1.Win.C1FlexGrid.4~C1.Win.C1FlexGrid.CellStyleEnum.html

    You can also check the “Subtotals” sample in the product sample demonstrating the same for reference. The sample is located in your machine at : \Documents\ComponentOne Samples\WinForms\v4.0\C1FlexGrid\CS\Subtotals

    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