Microsoft KB Archive/35887

= BC.EXE &quot;Internal Error&quot; Occurs if Line Number 0 Is Used =

Article ID: 35887

Article Last Modified on 8/16/2005

-

APPLIES TO


 * Microsoft QuickBasic 4.0
 * Microsoft QuickBASIC 4.0b
 * Microsoft QuickBasic 4.5 for MS-DOS
 * Microsoft BASIC Compiler 6.0
 * Microsoft BASIC Compiler 6.0b
 * Microsoft BASIC Professional Development System 7.0
 * Microsoft BASIC Professional Development System 7.1

-



This article was previously published under Q35887



SYMPTOMS
The GOTO 0 statement in the following program runs correctly in the QB.EXE or QBX.EXE environment, but BC.EXE flags it with an &quot;Internal error near xxx&quot; message at compile time (where the address xxx may vary).

&quot;An Internal Error near xxx&quot; also occurs, if you use a line number 0 and reference it with a RESTORE statement.

&quot;An Internal Error near xxx&quot; also occurs, if you use line number 0 with a GOSUB statement in Microsoft QuickBasic for MS-DOS, version 4.5, and Microsoft Basic Professional Development System for MS-DOS and MS OS/2, version 7.1.

These problems occur in BC.EXE in Microsoft QuickBasic versions 4.0, 4.0b, and 4.5, in Microsoft Basic Compiler versions 6.0 and 6.0b for MS-DOS and MS OS/2 (buglist6.00, buglist6.00b), and in Microsoft Basic Professional Development System (PDS) for MS-DOS and MS OS/2, versions 7.0 and 7.1 (buglist7.00, buglist7.10).

Microsoft is researching these problems and will post new information here as it becomes available.

As stated on page 9 of the &quot;Microsoft QuickBasic 4.0: Basic Language Reference&quot; manual for versions 4.0 and 4.0b, using 0 (zero) as a line number is not recommended. (This is also stated on page 697 of the &quot;Microsoft Basic 7.0: Programmer's Guide&quot; for Basic PDS 7.0 and 7.1.) The error ceases if you change the line number to a number or label other than 0.



MORE INFORMATION
The following program gives an &quot;Internal Error&quot; from BC.EXE in all product versions mentioned above: 0 PRINT &quot;Hello&quot; GOTO 0 The following code example gives an &quot;Internal Error&quot; in BC.EXE from QuickBasic versions 4.0, 4.0b, and 4.5, but works correctly in Basic PDS 7.0 and 7.1: PRINT &quot;Seattle Seahawks are going to the Superbowl!&quot; GOTO 0 PRINT &quot;NOT PRINTED&quot; 0 PRINT &quot;Don't you agree?&quot; GOTO 0 appears to work correctly in Basic PDS 7.0 and 7.1 if the 0 line label occurs after the GOTO 0 statement.

The following program gives an &quot;Internal Error&quot; from BC.EXE in all product versions mentioned above: 0 DATA 1, 2, 3 RESTORE 0

Additional query words: QuickBas BasicCom buglist4.00 buglist4.00b buglist4.50

Keywords: KB35887

-

[mailto:TECHNET@MICROSOFT.COM Send feedback to Microsoft]

© Microsoft Corporation. All rights reserved.