//滚轮事件:ScrollBox1: TScrollBox; 
procedure TfrmReleateGQAccount.ScrollBox1MouseWheel(Sender: TObject; //也可以写在窗体事件中
  Shift: TShiftState; WheelDelta: Integer; MousePos: TPoint;
  var Handled: Boolean);
begin
   if WheelDelta<0 then
    ScrollBox1.Perform(WM_VSCROLL,SB_LINEDOWN,0) //发送消息
  else
    ScrollBox1.Perform(WM_VSCROLL,SB_LINEUP,0);
end;
object scrlbx1: TScrollBox
  Left = 1
  Top = 1
  Width = 479
  Height = 379
  Align = alClient
  Color = clBtnFace
  ParentColor = False
  TabOrder = 0
  ExplicitLeft = 6
  ExplicitTop = 2
end
控件窗体文件

相关文章:

  • 2021-08-04
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2021-07-21
猜你喜欢
  • 2022-12-23
  • 2022-12-23
  • 2021-08-22
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
相关资源
相似解决方案