type TGridCoord = record
X: Longint;
Y: Longint;
end;
function MouseCoord(X, Y: Integer): TGridCoord;
得到行和列Returns the row and column indexes of the cell that contains a point specified in screen coordinates.
Cell: TGridCoord;
Cell := MouseCoord(XPos, YPos);