User32MouseEvent Method
Note: This API is now obsolete.
Synthesizes mouse motion and button clicks.
Namespace: DevCase.Win32.NativeMethodsAssembly: DevCase.net48 (in DevCase.net48.dll) Version: 6.0.0.0 (6.0)
XMLNS for XAML: Not mapped to an xmlns.
[DllImportAttribute("User32.dll", EntryPoint = "mouse_event")]
[ObsoleteAttribute("This function has been superseded. Use SendInput instead.",
false)]
public static void MouseEvent(
MouseEventFlags flags,
int x,
int y,
int data,
UIntPtr extraInfo
)
<DllImportAttribute("User32.dll", EntryPoint := "mouse_event">]
<ObsoleteAttribute("This function has been superseded. Use SendInput instead.",
false)>
Public Shared Sub MouseEvent (
flags As MouseEventFlags,
x As Integer,
y As Integer,
data As Integer,
extraInfo As UIntPtr
)
Dim flags As MouseEventFlags
Dim x As Integer
Dim y As Integer
Dim data As Integer
Dim extraInfo As UIntPtr
User32.MouseEvent(flags, x, y, data,
extraInfo)
public:
[DllImportAttribute(L"User32.dll", EntryPoint = L"mouse_event")]
[ObsoleteAttribute(L"This function has been superseded. Use SendInput instead.",
false)]
static void MouseEvent(
MouseEventFlags flags,
int x,
int y,
int data,
UIntPtr extraInfo
)
[<DllImportAttribute("User32.dll", EntryPoint = "mouse_event")>]
[<ObsoleteAttribute("This function has been superseded. Use SendInput instead.",
false)>]
static member MouseEvent :
flags : MouseEventFlags *
x : int *
y : int *
data : int *
extraInfo : UIntPtr -> unit
No code example is currently available or this language may not be supported.
Parameters
- flags MouseEventFlags
-
Controls various aspects of mouse motion and button clicking.
- x Int32
-
The mouse's absolute position along the x-axis or its amount of motion since the last mouse event was generated,
depending on the setting of Absolute.
Absolute data is specified as the mouse's actual x-coordinate; relative data is specified as the number of mickeys moved.
A mickey is the amount that a mouse has to move for it to report that it has moved.
- y Int32
-
The mouse's absolute position along the y-axis or its amount of motion since the last mouse event was generated,
depending on the setting of Absolute.
Absolute data is specified as the mouse's actual y-coordinate; relative data is specified as the number of mickeys moved.
A mickey is the amount that a mouse has to move for it to report that it has moved.
- data Int32
-
Specifies additional info for flags parameter.
- extraInfo UIntPtr
-
An additional value associated with the mouse event.
An application calls GetMessageExtraInfo function to obtain this extra information.