Simulate input/Mouse: Difference between revisions

Content added Content deleted
No edit summary
(Added Python example (works on windows))
Line 166: Line 166:
AW_MouseClick(#PB_MouseButton_Left, 50, 50)</lang>
AW_MouseClick(#PB_MouseButton_Left, 50, 50)</lang>


=={{header|Python}}==
In Windows (GUI can be externally created):
<lang Python>import ctypes

def click():
ctypes.windll.user32.mouse_event(0x2, 0,0,0,0)
ctypes.windll.user32.mouse_event(0x4, 0,0,0,0)

click()</lang>
=={{header|Tcl}}==
=={{header|Tcl}}==
===Within an Application===
===Within an Application===