home *** CD-ROM | disk | FTP | other *** search
- HUGEARR.DLL
- History of Public Modifications
-
- Microsoft Customer Support uploaded to the MSL a DLL to support huge
- arrays from Visual BASIC v1.0. Because the source was included, and
- no copyright posted, HUGEARR.DLL has a lot of educational potential.
- I found a small bug in HUGEARRY.DLL, or rather an oversight, in that
- HugeUbound was defined as an integer function, thus preventing its
- use on...huge arrays. The bug fix was simple and this ZIP file
- contains the modified files. It occurred to me that there were a
- number of array related functions that might be added to the DLL
- so I started this history file in hopes that modifications could
- be made in one place and re-posted over this file.
- Jonathan Zuck, User Friendly, Inc. 06/26/91
-
- ========================================================================
- 06/10/91
- ========================================================================
- 06/10/91 Original Files: MS Customer Support
-
- HUGEARR.BAS 05/13/91
- HUGEARR.C 06/10/91
- HUGEARR.DEF 05/09/91
- HUGEARR.DLL 06/10/91
- HUGEARR.H 05/10/91
- HUGEARR.TXT 06/04/91
- MAKEFILE 05/10/91
-
-
- ========================================================================
- 06/26/91
- ========================================================================
- 06/26/91 HUGEUBOUND now returns LONG User Friendly, Inc.
-
- Changed Files:
-
- HUGEARR.BAS 06/26/91
- HUGEARR.TXT 06/26/91
- HUGEARR.C 06/26/91
- HUGEARR.H 06/26/91
- HUGEARR.DLL 06/26/91
-
- New Files:
-
- History.TXT 06/26/91
-
- Remarks:
- The purpose of HUGEARR.DLL was to support huge arrays. However,
- HugeUbound was defined as an integer function, making it impossible
- to get consistent results when the array had more than 32k elements.
- The changes here are quite simple:
-
- HUGEARR.BAS
- Changed the Declare statment for HugeUbound
- HUGEARR.TXT
- Modified HugeUbound example
- HUGEARR.C
- Changed the function return to LONG
- Changed the ubound variable declaration to LONG
- HUGEARR.H
- Changed the HugeUbound declaration to LONG
- HUGEARR.DLL
- Re-built using NMAKE
-
-
-
- ========================================================================
- 09/06/92
- ========================================================================
- 09/06/92
-
- Changed Files:
- ------------------------
- HUGEARR.C 09/10/92
- HUGEARR.DLL 09/06/92
- HISTORY.TXT 09/11/92
-
-
- Remarks:
- ========
- HugeRedim not working correctly.
-
- Gary Garrison reported this bug on CIS on 9/2/92:
-
- < If I dimension the same array with an upper bound of >
- < 5,000 then redimension the array with an upper bound of >
- < 10,000 using HugeRedim I get an error (RC=-1). >
-
- Besides the Error code, my own experience was that the array contents
- were being preserved, but after the HugeReDim, additional records added
- beyond the UBound of the old array size could not be accessed. Instead,
- when doing a GetHugeEL on those new "tail end" records, I kept getting
- the last record of the *old* array instead.
-
- Gary's fix is as follows:
- ---------------------------
-
- Excerpt from Gary's message on CIS:
-
- I started to try out what you suggested and noticed the flags on the
- GlobalAlloc and GlobalReAlloc were combined as follows:
-
- GMEM_MOVEABLE || GMEM_ZEROINIT
-
- They should be:
-
- GMEM_MOVEABLE | GMEM_ZEROINIT
-
- or to make it easier, just GHND which is a combination of the two.
-
- BTW.. this is the way it comes with the PTK so everyone using it from the PTK
- would have the same problem.
-
- Changed the GlobalAlloc and GlobalReAlloc to just use GHND as a flag and
- everything works fine.
-
-
- Hope Gary's fix helps you as much as it did me. Best Regards,
-
- Bob Scherer, Newport Beach CA
- CIS#: 76237,514
-
- ========================================================================
-