Gerrit Broekhuis
Programmer
Hi,
Is there a way to count the number of records that are actually visible in a grid? For example when scrolling a grid towards the bottom not all records will be shown and I need to know the number of gridrows that actually show data.
I know how to calculate the number of records that can be shown (partially) on a grid. The table can have more or less records than the grid can show. And when the grid is scrolled vertically perhaps only a few records are actually visible in the grid. And I need code to calculate the number of visible records on the grid. Even when you have a grid that can show 30 records and you have a table with 300 records, only one record may be visible on the grid after scrolling.
As a human being it’s easy to count the number of visible records, but in code it’s not that easy apparently.
In this screenimage you see a sample grid with 6 visible records (due to scrolling). This particular grid can contain 16 records. The table has 160 records. In real life, with form and grid resizing things will be even more different.
I calculated the number of records the grid can contain (16). But how can I get count the number of visible records (6)?
Regards, Gerrit
Is there a way to count the number of records that are actually visible in a grid? For example when scrolling a grid towards the bottom not all records will be shown and I need to know the number of gridrows that actually show data.
I know how to calculate the number of records that can be shown (partially) on a grid. The table can have more or less records than the grid can show. And when the grid is scrolled vertically perhaps only a few records are actually visible in the grid. And I need code to calculate the number of visible records on the grid. Even when you have a grid that can show 30 records and you have a table with 300 records, only one record may be visible on the grid after scrolling.
As a human being it’s easy to count the number of visible records, but in code it’s not that easy apparently.
In this screenimage you see a sample grid with 6 visible records (due to scrolling). This particular grid can contain 16 records. The table has 160 records. In real life, with form and grid resizing things will be even more different.
I calculated the number of records the grid can contain (16). But how can I get count the number of visible records (6)?
Regards, Gerrit