Question and Answer Database FAQ1897C.txt Making a form scroll programatically in Builder Category :Windows API Platform :All Product :C++Builder 1.x Question: How do you get a TForm's scrollbars to respond the standard scrolling keys (like PageUp, PageDown, Home, End, Up, and Down)? Answer: You would use the WM_VSCROLL message in the form's OnKeyDown Event: void __fastcall TForm1::FormKeyDown( ... ) { if (Key == VK_KEYDOWN) SendMessage(Handle, WM_VSCROLL, SB_LINEDOWN, NULL); if (Key == VK_NEXT) SendMessage(Handle, WM_VSCROLL, SB_PAGEDOWN, NULL); // etc } 7/2/98 10:32:32 AM
Last Modified: 01-SEP-99