Limit the cursor movement within a window client  

Send By: Q3 Team
Web : http://www.q3.nu
Email: dlib@q3.nu
Date: 09/01/00

Tip accessed 589 times

 


To limit it:


 procedure TForm1.Button1Click(Sender: TObject);
 var
   Rectangulo: TRect;
 begin
   With Rectangulo do
   begin
    Left:=10;      {Izquierda}
    Right:=300;    {Derecha}
    Top:=10;       {Arriba}
    Bottom:=300;   {Abajo}
   end;
   ClipCursor(@Rectangulo);
 end;



To restore it:


          ClipCursor(nil);