home *** CD-ROM | disk | FTP | other *** search
-
- Text and List Boxes can only hold a maximum of 64K. This program
- is an attempt to simulate a List Box and view files that are much
- larger using a Picture Box and a Vertical Scroll Bar.
-
- The file is read into a Huge Array. Note that the FileArray() is
- dimensioned as:
-
- Dim FileArray(0 To 10000) As String * 80
-
- You can change the max number of elements and the fixed line size
- (the 80) if you have different requirements.
-
- The lines are "displayed" in Picture2 (which is off-screen) and
- then copied to Picture1 which is the "List Box" that you see. As
- I understand it, it's faster to do it this way rather than print
- the lines directly to Picture1 (with Picture1.AutoRedraw = true).
-
- I'm not sure if the scrolling occurs at a fast enough rate or
- not. I have a Gateway Pentium and everything is fast <g>. (If
- you know a faster way to do it, please let me know!)
-
- NLinesToShow is set to 15 in Form_Load. This is the number of
- lines that are displayed in the "List Box" (Picture1). You can
- change it if you want to (by changing the 15). The height of
- Picture1 is determined by the font, the font size, and
- NLinesToShow. If you want to change the font and/or font size,
- change it for Picture2 (not Picture1).
-
- -> Note that you will need to edit the TEXTVIEW.MAK file if your
- CMDIALOG.VBX is not in the C:\WINDOWS\SYSTEM directory
-
- Use the code if you find it useful. No cost, no warranty.
-
- If you have any questions, comments, or suggestions, feel free to
- zap me a message. I usually hang out in MSBASIC, Section 5.
-
- Bob Craig CIS: 70042,1041 December 20, 1993.
- Salt Spring Island
- BC Canada
-
-
-
-
-
-
-