This is a migrated thread and some comments may be shown as answers.

Scroll into view

1 Answer 429 Views
Grid
This is a migrated thread and some comments may be shown as answers.
Jonathan
Top achievements
Rank 1
Jonathan asked on 14 Jan 2013, 10:36 PM
How can I scroll a data item into view? (Even if it is on a different page).

1 Answer, 1 is accepted

Sort by
0
Alexander Valchev
Telerik team
answered on 16 Jan 2013, 03:27 PM
Hi Jonathan,

If I understood correctly you would like to scroll the Grid so a given row becomes visible. In that case you may use the jQuery scrollTop method to scroll the content. As an example:
var grid = $("#grid").data("kendoGrid"),
    content = $(".k-grid-content");
//find the row element
content.scrollTop(rowElement.offset().top); //scroll the content

If the row which corresponds to the dataItem does not persist on the current page, at first you have to switch the pager through the page method.

I hope this will help. In case I misunderstood your question, please provide more information about what you would like to achieve and if possible an example. Thank you in advance.

Kind regards,
Alexander Valchev
the Telerik team
Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
Tags
Grid
Asked by
Jonathan
Top achievements
Rank 1
Answers by
Alexander Valchev
Telerik team
Share this question
or