NUnitForms Class Library

MouseController.Press Method (MouseButtons, PointF)

Simulate pressing the mouse button(s) at the specified PointF.

[Visual Basic]
Overloads Public Sub Press( _
   ByVal buttons As MouseButtons, _
   ByVal point As PointF _
)
[C#]
public void Press(
   MouseButtons buttons,
   PointF point
);

Parameters

buttons
A bitwise combination of the MouseButtons enumeration values.
point
A PointF, relative to the control under test, to move the mouse to.

Remarks

Press positions the mouse over the control under test at the specified point and then simulates pressing the specified buttons.

Exceptions

Exception TypeCondition
NotSupportedException When buttons contains MouseButtons.XButton1 or MouseButtons.XButton2 and the installed mouse does have 4 or 5 buttons, respectively.

See Also

MouseController Class | NUnit.Extensions.Forms Namespace | MouseController.Press Overload List