• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 246
  • Last Modified:

Ignore

Ignore
0
ginsonic
Asked:
ginsonic
  • 3
1 Solution
 
ginsonicAuthor Commented:
My try :

    GetCursorPos(StartPos);
    EndPos.x := 200;
    EndPos.y := 200;
    PixelMov := 13;
    Mover.x := 0;
    Mover.y := Round(Sqrt(SumOfSquares([abs(EndPos.y-StartPos.y),abs(EndPos.x-StartPos.x)]))) div PixelMov;
    Radian1 := DegToRad(180 * (1 + ArcTan2(EndPos.y-StartPos.y, EndPos.x-StartPos.x) / Pi));

While (Mover.x < Mover.y) or (Mover.x < 1000) do begin
    SetCursorPos(Round(StartPos.x-Cos(Radian1)*(PixelMov*Mover.x)),
            Round(StartPos.y-Sin(Radian1)*(PixelMov*Mover.x)));
    Inc(Mover.x);
    Sleep(1);
   end;
SetCursorPos(EndPos.x, EndPos.y);
0
 
ginsonicAuthor Commented:
Already solve my problem.
0
 
kretzschmarCommented:
? nick, what is the question ?
sorry, for not ignoring
0
 
MoondancerCommented:
100 points refunded, questions closed.

You cannot delete a questions once comments by anyone have been added without posting in Community Support and requesting assistance.

Moondancer - EE Moderator
0
 
ginsonicAuthor Commented:
I wish to use a linear movement for my mouse without a timer . You have already the code. But when I remove the timer and use top code this don't work how I wish:(

I don't fix it, just I don't use it anymore in my help application.
0

Featured Post

New feature and membership benefit!

New feature! Upgrade and increase expert visibility of your issues with Priority Questions.

  • 3
Tackle projects and never again get stuck behind a technical roadblock.
Join Now