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

Grid virtual scrolling not working after adding data using datasource.add

3 Answers 179 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
Jason
Top achievements
Rank 1
Jason asked on 11 Apr 2014, 11:14 AM
I'm having issues after adding rows into a dataset after the initial load of the grid, where the vertical scrollbar vanishes and the displayed data seems to revert back to the top of the dataset. My actual usage case is fairly complicated so I've created a jsbin which shows the same problem.

http://jsbin.com/vilahoji/2/

As you can see I'm populating the first grid by adding rows to the datasource, the second grid has 100 rows when the datasource is created.

3 Answers, 1 is accepted

Sort by
0
Alexander Popov
Telerik team
answered on 15 Apr 2014, 07:10 AM
Hello Jason,

I am afraid that this scenario is not fully supported. Basically, virtual scrolling uses ranges instead of pages to determine which items to be displayed, and adding a new item results in miscalculated ranges, which in turn breaks the scrolling. I would recommend removing the DataSource's pageSize option, as shown in this updated example.

Regards,
Alexander Popov
Telerik
 
Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
 
0
Henry
Top achievements
Rank 1
answered on 08 Jun 2015, 07:33 PM
Has there been any response to this bug report? 
0
Alexander Popov
Telerik team
answered on 10 Jun 2015, 10:51 AM
Hello Henry,

This is a limitation that is mentioned in the documentation here and here. Virtual scrolling uses ranges instead of pages to determine which items to be displayed and adding a new item or deleting an existing one results in miscalculated ranges, which in turn breaks the scrolling. I am afraid at this point there is no workaround that we can recommend in order to get working CRUD operations along with virtual scrolling. 

Regards,
Alexander Popov
Telerik
 
Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
 
Tags
General Discussions
Asked by
Jason
Top achievements
Rank 1
Answers by
Alexander Popov
Telerik team
Henry
Top achievements
Rank 1
Share this question
or