使用DevExpress进行服务器端分页而不使用XPO

时间:2022-06-03 15:03:45

Is there any (relatively) easy way to implement server-side paging using DevExpress controls (either Win- or Web-ones) without using an XPO data source? By server-side paging I mean control retrieving only the records it needs to display from the database, not the whole table.

有没有(相对)简单的方法使用DevExpress控件(Win或Web-one)实现服务器端分页而不使用XPO数据源?通过服务器端分页,我的意思是控制只检索它需要从数据库而不是整个表中显示的记录。

3 个解决方案

#1


1  

You must create custom paging control (Don' t use DevEx' s paging). Send current page and page size to procedure as parameter or use directly in your query.

您必须创建自定义分页控件(不要使用DevEx的分页)。将当前页面和页面大小作为参数发送到过程或直接在查询中使用。

How to use this value sample in MS SQL is this link : http://msdn.microsoft.com/en-us/library/ms186734.aspx

如何在MS SQL中使用此值示例是此链接:http://msdn.microsoft.com/en-us/library/ms186734.aspx

In Oracle and other databases, you can do it too with different tecniques. Best regards.

在Oracle和其他数据库中,您也可以使用不同的技术来完成它。最好的祝福。

#2


0  

If your data source is LINQ-capable, recent DevExpress versions should be able to do the right thing.

如果您的数据源支持LINQ,那么最近的DevExpress版本应该能够做正确的事情。

Otherwise, you need to implement IListServer. I'm struggling with the same thing right now, so this is not exactly an "answer". I have not found a working example, but there's some useful information in their knowledge base here: http://www.devexpress.com/Support/Center/KB/p/A1022.aspx

否则,您需要实现IListServer。我现在正在努力做同样的事情,所以这不是一个“答案”。我还没有找到一个有效的例子,但是他们的知识库中有一些有用的信息:http://www.devexpress.com/Support/Center/KB/p/A1022.aspx

#3


0  

If you don't want to use LINQ you could try this example for an ObjectDataSource: http://www.devexpress.com/Support/Center/e/E166.aspx

如果您不想使用LINQ,可以尝试使用此示例来获取ObjectDataSource:http://www.devexpress.com/Support/Center/e/E166.aspx

#1


1  

You must create custom paging control (Don' t use DevEx' s paging). Send current page and page size to procedure as parameter or use directly in your query.

您必须创建自定义分页控件(不要使用DevEx的分页)。将当前页面和页面大小作为参数发送到过程或直接在查询中使用。

How to use this value sample in MS SQL is this link : http://msdn.microsoft.com/en-us/library/ms186734.aspx

如何在MS SQL中使用此值示例是此链接:http://msdn.microsoft.com/en-us/library/ms186734.aspx

In Oracle and other databases, you can do it too with different tecniques. Best regards.

在Oracle和其他数据库中,您也可以使用不同的技术来完成它。最好的祝福。

#2


0  

If your data source is LINQ-capable, recent DevExpress versions should be able to do the right thing.

如果您的数据源支持LINQ,那么最近的DevExpress版本应该能够做正确的事情。

Otherwise, you need to implement IListServer. I'm struggling with the same thing right now, so this is not exactly an "answer". I have not found a working example, but there's some useful information in their knowledge base here: http://www.devexpress.com/Support/Center/KB/p/A1022.aspx

否则,您需要实现IListServer。我现在正在努力做同样的事情,所以这不是一个“答案”。我还没有找到一个有效的例子,但是他们的知识库中有一些有用的信息:http://www.devexpress.com/Support/Center/KB/p/A1022.aspx

#3


0  

If you don't want to use LINQ you could try this example for an ObjectDataSource: http://www.devexpress.com/Support/Center/e/E166.aspx

如果您不想使用LINQ,可以尝试使用此示例来获取ObjectDataSource:http://www.devexpress.com/Support/Center/e/E166.aspx