Link to home
Start Free TrialLog in
Avatar of mikezang
mikezang

asked on

How to scoll two ScrollBox simultaneous

I have two ScrollBox on form, they have the same size, when I scroll one of them, I hope another will be scrolled simultaneous, what can I do?
Avatar of zion29
zion29

You could always fake it with hiding the vertical scrollbar (visible:=false)  in both scrollboxes and put in a TScrollbar with something like:

procedure TForm1.ScrollBar1Change(Sender: TObject);
begin
  ScrollBox1.VertScrollBar.Position:=Scrollbar1.Position;
  ScrollBox2.VertScrollBar.Position:=Scrollbar1.Position;
end;
Avatar of mikezang

ASKER

I hope that I still can use both V and H ScrollBar in two ScrollBox, then I hope they can scroll simultaneous, do you have any idea?
By the way, can you explain more detail about your idea?
ASKER CERTIFIED SOLUTION
Avatar of geobul
geobul

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Great!