Lprocedure TForm2. NewWndProc (var _msg: TMessage);
Var
Scrollinfo1: TScrollinfo;
Pos: integer;
The begin
FOldWndProc (_msg);
With the _msg do
The begin
Case Msg of
WM_VSCROLL:
The begin
Scrollinfo1. CbSize:=sizeof (Scrollinfo1);
Scrollinfo1. FMask:=SIF_ALL;
Getscrollinfo (listview1. Handle, SB_VERT scrollinfo1);
Pos:=Scrollinfo1. NPos;
If the _msg. WParam> 0 then
The begin
Sendmessage (listview2. Handle, WM_VSCROLL SB_LINEUP, 0).
Sendmessage (listview3. Handle, WM_VSCROLL SB_LINEUP, 0).
End
The else
The begin
Sendmessage (listview2. Handle, WM_VSCROLL SB_LINEDOWN, 0).
Sendmessage (listview3. Handle, WM_VSCROLL SB_LINEDOWN, 0).
end;
end;
end;
end;
end;
CodePudding user response:
Can use the controls, the three listview is set to the same height, and then call the same scroll bar, can use BusinessSkinForm controls