BUG: WINDOW OUTPUT Output Goes to Wrong Window in Interpreter (20591)



The information in this article applies to:

  • Microsoft BASIC Interpreter for Apple Macintosh 3.0
  • Microsoft BASIC Interpreter for Apple Macintosh 2.0
  • Microsoft BASIC Interpreter for Apple Macintosh 2.1

This article was previously published under Q20591

SYMPTOMS

The sample program shown in the More Information section below demonstrates a problem with the WINDOW OUTPUT n statement in interpreted programs. In the program, the PRINT and LINE output correctly appears the first time in window 1 (the current output window); however, after the INPUT statement is invoked, all subsequent output statements incorrectly go to window 2.

RESOLUTION

In compiled QuickBasic programs, PRINT and LINE output correctly goes to window 1.

To eliminate the problem, place another WINDOW OUTPUT 1 statement after the INPUT statement.

STATUS

Microsoft has confirmed this to be a bug in the Microsoft products listed at the beginning of this article. We are researching this problem and will post new information here in the Microsoft Knowledge Base as it becomes available.

MORE INFORMATION

Program Code Sample to Reproduce Problem

WINDOW 1,"Window 1",(4,40)-(510,200)
WINDOW 2,"Window 2",(4,220)-(510,340)
WINDOW OUTPUT 1
Display:
PRINT "This should always print in window 1"
LINE (1,1)-(30,30)        ' This line should always go to window 1.
INPUT "OK";R$
IF F$<> "exit" THEN Display
				

Modification Type:MajorLast Reviewed:10/20/2003
Keywords:kbbug KB20591