Scrolling a Window
- Posted by Ron Tarrant <rtarrant at sympatico.ca> Sep 09, 2002
- 403 views
I am using win32lib to create a window that has a number of text controls arranged in rows and columns (tiled as opposed to cascading). I want to be able to add rows/columns at will, but at some point, I'll need to be able to scroll the client area of the window in order to see the new text controls that I've added. So what I'm looking for is a simple example of adding scrollbars to a window, then processing scrollbar messages (or however it's done) to scroll the contents of the window left/right/up/down. Does anyone know how to do this? On a separate topic, I have attached a keyDown handler to this same window and I'm getting keyCodes for most keys, but not for the Tab key. I wrote a simple procedure that tells me the raw keyCode value and it works for a number of other keys I've tried, but when I press the Tab key, I get nothing. Does anyone know why? If I haven't given enough info here, or haven't explained this very clearly, please let me know and I'll try again. -Ron T.