简体   繁体   English

DevExpress列过滤忽略GridViewList上的值

[英]DevExpress Column Filtering Ignores Values on GridViewList

My main issue is that in my gridviewlist when I filter a column I get the wrong value from my code behind compared to when I don't use a filter. 我的主要问题是,在我的gridviewlist中,当我过滤一列时,与不使用过滤器相比,我从后面的代码中得到了错误的值。 I've found out what causes this error but I'm not sure why. 我已经找到了导致此错误的原因,但我不确定为什么。 When I filter and select a value , that value is not stored in my db and therefore it never reaches my code. 当我筛选并选择一个值时,该值未存储在我的数据库中,因此它永远不会到达我的代码。 When I don't filter and select a value , that value is normally stored in my db as expected and further used by my method to give the correct outcome. 当我不过滤并选择一个值时,该值通常会按预期存储在我的数据库中,并由我的方法进一步使用以提供正确的结果。

Any ideas? 有任何想法吗?

PS: I Don't have 10 reputation and for that I'm only able to post link-images PS:我没有10个声誉,因此我只能发布链接图像

Not Filtered UI 未过滤的用户界面

[未过滤的用户界面]

Not Filtered SQL 未过滤的SQL
未过滤的SQL =========================================================================== ================================================== =========================

在此处输入图片说明 =========================================================================== ================================================== =========================

在此处输入图片说明 =========================================================================== ================================================== =========================

I believe I've figured out why this issue occurs. 我相信我已经弄清楚了为什么会发生此问题。 While the code behind retrieved the value using DevExpress commands ( ie gridviewlist.getrowcellvalue(rowhandle , column) duing fitlering it seemed that the rowhandle was wrong . That could mean that when all rows are visible in a gridview , rowhandle picks up the correct row index. But when filtering it seems that somehow the row index was incorrect. As it was trying to adjust with the temporary removal of rows (filtering) but failed miserably . 尽管后面的代码使用DevExpress命令(即gridviewlist.getrowcellvalue(rowhandle,column))在拟合过程中检索了该值,但该行句柄似乎是错误的,这可能意味着当在gridview中所有行均可见时,rowhandle会选择正确的行索引但是,当进行过滤时,似乎行索引是不正确的,因为它试图通过临时删除行来进行调整(过滤),但是失败了。

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

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