permanent footer row in datagridview

ankit goel 766 Reputation points
2023-09-21T12:32:58.41+00:00

hi ,

is there a way by which our datagridview control could have a footer row below exactly after the 12 rows and if the rows in the datagridview increases , suppose by 2 . it should always be at last position but it always should be after 12 rows . the data is coming from a dataset .

Windows Forms
Windows Forms
A set of .NET Framework managed libraries for developing graphical user interfaces.
1,910 questions
C#
C#
An object-oriented and type-safe programming language that has its roots in the C family of languages and includes support for component-oriented programming.
11,115 questions
0 comments No comments
{count} votes

Accepted answer
  1. Karen Payne MVP 35,461 Reputation points
    2023-09-21T13:39:04.36+00:00

    There are semi decent solutions out there such as found here but they and others do not account for sorting. Perhaps consider placing a second DataGridView below the first DataGridView, hide the row and column headers and use this for your footer or place labels below the main DataGridView and update as needed.


1 additional answer

Sort by: Most helpful
  1. KOZ6.0 6,580 Reputation points
    2023-09-21T15:25:10.0733333+00:00

    I made a sample.

    DataGridViewWithFooter.cs

    enter image description here


Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.