为Grid的列表头指定排序动作

  • Post author:
  • Post category:其他


一个grid由几个column组成,每个column都有header,header支持click事件,可以通过下面代码来给列表头排序,

IF this.Caption = ‘Name↓’ then

SET ORDER TO ‘name’ ascending

this.Caption = ‘Name↑’

ELSE

SET ORDER TO ‘name’ descending

this.Caption = ‘Name↓’

ENDIF

GO top

thisform.Refresh()



版权声明:本文为zhjno1xp原创文章,遵循 CC 4.0 BY-SA 版权协议,转载请附上原文出处链接和本声明。