I have too many data to show. How to index it in the following figure

4 posts, 0 answers
  1. Ricardo
    Ricardo avatar
    22 posts
    Member since:
    Dec 2018

    Posted 22 Feb 2019 Link to this post

    Dear All,

    I have too many data to show. How to index it in the following figure

    When you use a datagridview, it will be automatically added, but how do you do that in RadGridView

    Is this possible...

    Best regards

  2. Hristo
    Admin
    Hristo avatar
    1519 posts

    Posted 22 Feb 2019 Link to this post

    Hello Ricardo,

    Thank you for writing.

    A possible solution is to handle the ViewCellFormatting event and to change the text of the cell element in the indent column according to the row index. We have an article in our documentation demonstrating how this can be achieved: https://docs.telerik.com/devtools/winforms/controls/gridview/cells/formating-examples/row-numbers.

    I hope this will help.

    Regards,
    Hristo
    Progress Telerik
    Get quickly onboarded and successful with your Telerik and/or Kendo UI products with the Virtual Classroom free technical training, available to all active customers. Learn More.
  3. Ricardo
    Ricardo avatar
    22 posts
    Member since:
    Dec 2018

    Posted 22 Feb 2019 in reply to Hristo Link to this post

    Dear Hristo,

    Thanks for your reply.But not what I wanted

    If I don't use the ViewCellFormatting event, is there any other way to achieve this?

    Can we do a SubClass to do that?

    Because I have so many watches, the workload is too heavy.

    Best regards

  4. Hristo
    Admin
    Hristo avatar
    1519 posts

    Posted 22 Feb 2019 Link to this post

    Hello Ricardo,

    The grid control is virtualized and the cell elements are reused to represent different logical cell objects: 
    Currently, this is the preferred approach for adding row indices in the indent column. Handling the event as seen in the documentation article should not in any way impact the performance of the control. 

    Regards,
    Hristo
    Progress Telerik
    Get quickly onboarded and successful with your Telerik and/or Kendo UI products with the Virtual Classroom free technical training, available to all active customers. Learn More.
Back to Top