Problem/Question/Abstract:
How to scroll a TMemo through code
Answer:
procedure TForm1.Edit1KeyDown(Sender: TObject; var Key: Word; Shift: TShiftState);
begin
if Key = VK_F8 then
SendMessage(Memo1.Handle, WM_VSCROLL, SB_PAGEDOWN, 0)
else if Key = VK_F7 then
SendMessage(Memo1.Handle, WM_VSCROLL, SB_PAGEUP, 0);
end;
Nincsenek megjegyzések:
Megjegyzés küldése