另外,Delphi.Net语言中的集合只能容纳64个元素。在内部,集合是把元素按单独的位存储的,集合中只能是序数类型,这使得超过64的序数值无法存储到集合中。如下代码将编译不过:
if c in ['a', 'b', 'c'] then
…
这是因为Ord('a') > 90,超过了64,所以无法存储到集合。
..........
只能一路or下去了
if (DataGrid.FocusedField.Index in [9,18,27,36,55]) or (DataGrid.FocusedField.Index=64) or (DataGrid.FocusedField.Index=73) or(DataGrid.FocusedField.Index=82) then
begin
///
end;