Microsoft KB Archive/67147

= Microsoft Knowledge Base =

Basic Files Limited to 32 MB Without DOS 4.00/4.01 Patch
Last reviewed: September 25, 1997

Article ID: Q67147

2.00 2.01 3.00 4.00 4.00b 4.50 MS-DOS kbprg kbfile

SUMMARY
QuickBasic or other programs that use file I/O (Input/Output) may give incorrect results when accessing files larger than 32 megabytes (MB) under MS-DOS versions 4.00 and 4.01. (MS-DOS 4.00 and later introduce the capability for file sizes larger than 32 MB.) This is a problem with MS-DOS 4.00 and 4.01, which can be corrected with a program called PATCH32M, which is available as described in the More Information section below.

This information applies to Microsoft QuickBasic versions 2.00, 2.01, 3.00, 4.00, 4.00b, and 4.50; to Microsoft Basic Compiler versions 6.00 and 6.00b for MS-DOS; and to Microsoft Basic Professional Development System (PDS) versions 7.00 and 7.10 for MS-DOS.

MORE INFORMATION
Under MS-DOS 4.00 and 4.01, when you append to files larger than 32 megabytes in length, Basic's LOF function returns incorrect values for the file length. Specifically, if you write to a random-access file, and the size moves past the 33,554,432 byte (32 MB) boundary, the file size given by MS-DOS's DIR command and Basic's LOF function may remain at the last even record boundary below 33,554,432 bytes. However, the file will be written properly, and a CHKDSK /F followed by a DIR will return the correct size.

This is a problem in MS-DOS versions 4.00 and 4.01, and can be corrected by running the patch program PATCH32M.EXE available in the self-extracting file PD0255.EXE.

You can find PD0255.EXE, a self-extracting file, on these services:

  Microsoft's World Wide Web site on the Internet On the www.microsoft.com home page, click the Support icon Click Knowledge Base, and select the product Enter kbfile PD0255.EXE, and click GO! Open the article, and click the button to download the file   Internet (anonymous FTP) ftp ftp.microsoft.com Change to the Softlib/Mslfiles folder Get PD0255.EXE   The Microsoft Network On the Edit menu, click Go To, and then click Other Location Type &quot;mssupport&quot; (without the quotation marks) Double-click the MS Software Library icon Find the appropriate product area Locate and Download PD0255.EXE   Microsoft Download Service (MSDL) Dial (425) 936-6735 to connect to MSDL Download PD0255.EXE 

For additional information about downloading, please see the following article in the Microsoft Knowledge Base:

ARTICLE-ID: Q119591 TITLE    : How to Obtain Microsoft Support Files from Online Services Additional information may be found by querying in the Microsoft Knowledge Base on the following words:

MS-DOS and 4.01 and 32 and MB