Show/hide mouse cursor

Posted in Forms

Use for this ShowCursor function. If parameter of this function is False, then cursor will be hidden.

procedure TForm1.Button1Click(Sender: TObject);
begin
  ShowCursor(False);  // Hide cursor
end;

procedure TForm1.Button2Click(Sender: TObject);
begin
  ShowCursor(True);  // Show cursor
end;