Returns one of the PointAtEnum enumerations, which indicates the kind of grid element beneath the specified coordinate.
Parameters
p
The Point in client coordinates.
Return Value
The PointAtEnum enumerations under the given coordinate.
Example
The following code uses the PointAt method of the grid to determine if the user has clicked on the RecordSelector in the MouseDown or MouseUp events:
Private Sub C1TrueDBGrid1_MouseUp(ByVal sender As Object, ByVal e As System.Windows.Forms.MouseEventArgs) Handles C1TrueDBGrid1.MouseUp
If Me.C1TrueDBGrid1.PointAt(e.p) = C1.Win.C1TrueDBGrid.PointAtEnum.AtRowSelect Then
' Your code goes here.
End If
End Sub
· C#
private void c1TrueDBGrid1_MouseUp(object sender, System.Windows.Forms.MouseEventArgs e)
{
if ((this.c1TrueDBGrid1.PointAt(e.p) == C1.Win.C1TrueDBGrid.PointAtEnum.AtRowSelect)
{
' Your code goes here.
}
}
· Delphi
procedure C1TrueDBGrid1_MouseUp(sender: System.Object; e: System.Windows.Forms.MouseEventArgs);
begin
if (Self.C1TrueDBGrid1.PointAt(e.p) = C1.Win.C1TrueDBGrid.PointAtEnum.AtRowSelect) then
begin
// Your code goes here.
end;
end;
See Also
C1TrueDBGrid Class | C1TrueDBGrid Members | C1.Win.C1TrueDBGrid Namespace | C1TrueDBGrid.PointAt Overload List
Send comments about this topic to ComponentOne. Copyright © ComponentOne LLC. All rights reserved. |