Example of Default Scrolling in ASP.NET Core Tree Grid Control
This sample demonstrates the TreeGrid component with the horizontal and vertical scrollbars to view the exceeded TreeGrid content.
The Tree Grid will show scrollbars when the content exceeds the element's width or height. The vertical and horizontal scrollbars will be displayed based on the following criteria.
- The vertical scrollbar appears when the total height of rows in the Tree Grid exceeds its element's height.
- The horizontal scrollbar appears when the sum of the column`s width exceeds the Tree Grid element's width.
The height
and width
properties are used to set the Tree Grid height and width, respectively. The value of these properties can be a numeric, pixel(px
) or percentage (%
).
In this demo, the height
and width
properties of the Tree Grid are set to 400 and auto,
respectively. Now, the Tree Grid will render with a vertical scrollbar when the total height of rows exceeds its element height and horizontal scrollbar will appear when the
total column width exceeds the element's width.