简体   繁体   English

我可以将具有百万条记录的数据库绑定到列表框吗?

[英]Can I bind a database with million records to a listbox?

Can I bind a list with over 1,000,000 records to a list box so that the list box is dynamically populated from the sqlite database as the user scrolls. 我可以将具有1,000,000条以上记录的列表绑定到列表框,以便在用户滚动时从sqlite数据库动态填充该列表框。

This is needed to show all our data in a list box without throwing an outofmemory exception. 这需要在列表框中显示我们的所有数据而不会引发内存不足的异常。 Is there any built in methods or framework's that I can use or do I need to build the control myself? 我是否可以使用任何内置方法或框架来构建控件?

Also are there any disadvantages of this. 也有任何缺点。

Cheers 干杯

You should virtualize UI and data loading. 您应该虚拟化UI和数据加载。 You can't just bind 1,000,000 item collection to the list without any code. 没有任何代码,您不能只将1,000,000个项目集合绑定到列表。 Read this tutorial about displaying large data sets . 阅读有关显示大数据集的本教程。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM