scrollToRow method

Future<void> scrollToRow(
  1. double rowIndex,
  2. {bool canAnimate = false,
  3. DataGridScrollPosition position = DataGridScrollPosition.start}

Scrolls the SfDataGrid to the given index.

If you want animation on scrolling, you can pass true as canAnimate argument.

Also, you can control the position of a row when it comes to view by passing the DataGridScrollPosition as an argument for position.


Future<void> scrollToRow(double rowIndex,
    {bool canAnimate = false,
    DataGridScrollPosition position = DataGridScrollPosition.start}) async {
  return scrollToCell(rowIndex, -1,
      canAnimate: canAnimate, rowPosition: position);