Thread View: comp.windows.ms.programmer
2 messages
2 total messages
Started by Samuelson S. Rehman
Wed, 26 Aug 1992 03:40
Question about Listbox 64K barrier
Author: Samuelson S. Rehman
Date: Wed, 26 Aug 1992 03:40
Date: Wed, 26 Aug 1992 03:40
32 lines
1686 bytes
1686 bytes
I'm a M2 UNIX programmer and programming in MS Windows is pretty new to me. I'm writing a program that can allow a user to select a record from a listbox. Now this list of record can easily exceed the 64K barrier. So my questions are: 1. How can I interrupt the user when he's trying to scroll down/up, so I can load the next/prev 64K segment from the file ? 2. And even if that can be done, how do I maintain the scrollbar to show the position of the bar within the whole database, but not just within the 64K segment ?? 3. If that is totally impossible, can anyone tell me where can I find information (books maybe) about writing a widget ( or whatever it's called in MS Windows ) ? Thanks! _______________________________ End of Message _________________________________ Yours Sincerely, |\ |||| ||||||||| (tm) |||\ |||| |||| Samuelson S. Rehman, ssr(SE/ADM) |||||\ |||| |||| [ Director, NIS Data Center ] |||||||\ |||| ||||||||| Systems Programmer, Newspager Infomation Systems Voice: (415) 873-4422 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Fax: (415) 873-4424 Email: sam@nca.com rnd_dept@nca.com sam@netcom.com
Re: Question about Listbox 64K barrier
Author: Tom W. Brown
Date: Wed, 26 Aug 1992 18:14
Date: Wed, 26 Aug 1992 18:14
43 lines
2489 bytes
2489 bytes
In article <k+bn2wq.sam@netcom.com>, sam@netcom.com (Samuelson S. Rehman) writes: |> |> I'm a M2 UNIX programmer and programming in MS Windows is pretty new to me. |> |> I'm writing a program that can allow a user to select a record from |> a listbox. Now this list of record can easily exceed the 64K barrier. |> So my questions are: |> |> 1. How can I interrupt the user when he's trying to scroll down/up, |> so I can load the next/prev 64K segment from the file ? |> |> 2. And even if that can be done, how do I maintain the scrollbar to |> show the position of the bar within the whole database, but not |> just within the 64K segment ?? |> Both of these concerns can be addressed by using an "OWNERDRAW" listbox. Check the documentation for CreateWindow with regard to the LBS_OWNERDRAWFIXED or LBS_OWNERDRAWVARIABLE styles. In a nutshell, these styles allow you to have a listbox where Windows does not need to store strings for each item in the list, rather a message is sent back to your application whenever a list item needs to be displayed (c.f. WM_DRAWITEM) allowing you to perform whatever file/memory buffering you desire. |> 3. If that is totally impossible, can anyone tell me where can |> I find information (books maybe) about writing a widget ( or |> whatever it's called in MS Windows ) ? The definitive documentation is probably the SDK (Software Developer's Kit) manual set from Microsoft Press, but there are plenty of books available that do a better job of "teaching" windows programming -- one of my favorites has always been Charles Petzold's book. Good luck, ---------------------------------------------------------------------------- Tom Brown | "Strange women, lying in ponds, distributing PE Nelson Systems | swords is no basis for a system of government." twbrown@pe-nelson.com | Monty Python and the Holy Grail ----------------------------------------------------------------------------
Thread Navigation
This is a paginated view of messages in the thread with full content displayed inline.
Messages are displayed in chronological order, with the original post highlighted in green.
Use pagination controls to navigate through all messages in large threads.
Back to All Threads