Control the location of the selected row, within the visible
Posted: Sat Jul 07, 2018 11:45 am
Delphi version: Seattle and Tokyo
TTeeGrid version: VCL & FMX Registered version-1.04
Multidevice Application (FMX)
Platform: WIN32
Hello,
For example, if there are 20 rows but only 5 can be displayed in the TTeegrid window, how can I get that pe. row 15 is displayed as the first visible, currently using the method TTeeGrid.Selected.Change, row 15 is shown as the last visible and selected row.
In other words, how can I control the selected row and its position in the visible window (eg at the beginning in the middle or at the end), when there are more rows than can be displayed.
I need this, because as I commented in another post, when a TTeeGrid is associated with a descendant of a TDataSet, when the value of a cell row is modified , the row is deselected and if it is editing pe. row 15, the selected row becomes 0.
When the behavior should be, keep the row selected.
You can review this behavior in your Demo TeeGrid_FMX_DataSet_Demo, modifying the address field of the last record of ClientDataSet1 and pressing the Enter key.
You can see that immediately after, the first record is displayed.
In case it helps, in this case the vertical scroll bar does not change, when it should be at the top, since it is showing the first row.
Greetings.
TTeeGrid version: VCL & FMX Registered version-1.04
Multidevice Application (FMX)
Platform: WIN32
Hello,
For example, if there are 20 rows but only 5 can be displayed in the TTeegrid window, how can I get that pe. row 15 is displayed as the first visible, currently using the method TTeeGrid.Selected.Change, row 15 is shown as the last visible and selected row.
In other words, how can I control the selected row and its position in the visible window (eg at the beginning in the middle or at the end), when there are more rows than can be displayed.
I need this, because as I commented in another post, when a TTeeGrid is associated with a descendant of a TDataSet, when the value of a cell row is modified , the row is deselected and if it is editing pe. row 15, the selected row becomes 0.
When the behavior should be, keep the row selected.
You can review this behavior in your Demo TeeGrid_FMX_DataSet_Demo, modifying the address field of the last record of ClientDataSet1 and pressing the Enter key.
You can see that immediately after, the first record is displayed.
In case it helps, in this case the vertical scroll bar does not change, when it should be at the top, since it is showing the first row.
Greetings.