Registriert seit: 10. Aug 2007
609 Beiträge
FreePascal / Lazarus
|
AW: mouse_event - Linker Mausklick verfehlt das Ziel
8. Dez 2010, 15:54
Wohin soll der Klick denn gehn?
Probier mal:
Delphi-Quellcode:
Mouse.CursorPos := Point(x,y);
if <Bedingung> then
begin
Sleep(50);
mouse_event(MOUSEEVENTF_LEFTDOWN, x, y, 0, 0);
Sleep(50);
mouse_event(MOUSEEVENTF_LEFTUP, x, y, 0, 0);
end
else
begin
Sleep(50);
mouse_event(MOUSEEVENTF_RIGHTDOWN, x, y, 0, 0);
Sleep(50);
mouse_event(MOUSEEVENTF_RIGHTUP, x, y, 0, 0);
end;
|
|
Zitat
|