0

我尝试从 TeeChart 9 为 XE10 编译文件 FMXTee.Chart.Grid.pas,该文件使用 FMX.Grid.pas 中的 CellControlByRow 函数获取以下代码:

使用 TColumnAccess(Columns[Col]).CellControlByRow(Row).BoundsRect.BottomRight 开始...结束;

我在使用 RAD XE10 Seattle 时运行良好,现在我尝试使用 RAD XE10.1 Berlin 但收到错误消息:[dcc32 Error] FMXTee.Chart.Grid.pas(1507): E2003 Undeclared identifier: 'CellControlByRow'

然后我比较了 XE10 包中的文件 FMX.Grid.pas 和 XE10.1 包中的 FMX.Grid.pas,有很多差异,特别是 XE10 中的 FMX.Grid.pas 中不再存在 CellControlByRow() 函数。 1.

现在,我想问一下如何更改使用 CellControlByRow 函数的代码,以便它可以在 RAD XE10.1 Berlin 中运行?

4

1 回答 1

0

我想建议你替换下面的代码:

result:=TColumnAccess(Columns[Col]).CellControlByRow(Row).BoundsRect.BottomRight;

接下来:

...
  var tmp : TFmxObject;
  begin 
  tmp:=TColumnAccess(Columns[Col]).CellControl;
  result:=TControl(tmp).BoundsRect.BottomRight
...

上面的代码应该可以解决您遇到的编译问题。你能确认一下吗?

于 2016-08-04T14:32:11.713 回答