User32PtInRect(NativeRectangle, NativePoint) Method

Determines whether the specified point lies within the specified rectangle.

A point is within a rectangle if it lies on the left or top side or is within all four sides.

A point on the right or bottom side is considered outside the rectangle.

Definition

Namespace: DevCase.Win32.NativeMethods
Assembly: DevCase.net48 (in DevCase.net48.dll) Version: 6.0.0.0 (6.0)
XMLNS for XAML: Not mapped to an xmlns.
[DllImportAttribute("User32.dll")]
public static bool PtInRect(
	in NativeRectangle refRect,
	NativePoint pt
)

Parameters

refRect  NativeRectangle
A pointer to a NativeRectangle structure that contains the specified rectangle.
pt  NativePoint
A NativePoint structure that contains the specified point.

Return Value

Boolean
If the specified point lies within the rectangle, the return value is .

If the specified point does not lie within the rectangle, the return value is

Remarks

See Also