如何创建一个帮助器类,在Datagrid中为Windows Mobile开发显示每页10个项目 [英] how to create a helper class to show 10 items per page in Datagrid for windows mobile development

查看:57
本文介绍了如何创建一个帮助器类,在Datagrid中为Windows Mobile开发显示每页10个项目的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述





i正在使用带有VS2008的c#进行Windows移动开发,因为它有很多数据,我想创建一个帮助类来制作Datagrid每页显示10个项目。它也可以翻页和翻页。通常我会使用datagrid.datasouce = list将List绑定到datagrid,这并不难让这个工作,但任何人都可以给我一些关于如何为此做一个帮助类的想法。



谢谢



i am doing windows mobile development using c# with VS2008, since it got lots of data, i would like to create a helper class to make the Datagrid show 10 items per page. And it can be page up and page down as well. Normally i would bind the List to the datagrid using datagrid.datasouce= list, It''s not hard to make this work ,but can anyone give me some idea about how to make a helper class about this.

thanks

推荐答案

创建一个新类,然后输入一个变量taht存储页面限制(在本例中为10)。

但是,它可以是可配置的。





然后传递集合并在帮助程序中过滤掉它。

仅返回要在griview中显示的那一组。
Create a new class and then put in a variable taht stores the page limit (10 in this case).
However, it could be congigurable.


Then pass the collection and filter it out in the helper.
Return only that set that you want to display in the griview.


这篇关于如何创建一个帮助器类,在Datagrid中为Windows Mobile开发显示每页10个项目的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆