GridLookUpEdit设置索引

时间:2012-12-15 15:09:31

标签: c# winforms devexpress

GridLookUpEdit我想用两个按钮改变位置 我可以通过

获得索引
XGridLookUpEdit.Properties.GetIndexByKeyValue(XGridLookUpEdit.EditValue);

但我不知道如何设置

感谢

1 个答案:

答案 0 :(得分:0)

int x = XGridLookUpEdit.Properties.GetIndexByKeyValue(XGridLookUpEdit.EditValue);
XGridLookUpEdit.EditValue = 
    XGridLookUpEdit.Properties.View.GetRowCellValue(x + 1, "id");